llonebot-dist 7.0.0 → 7.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/llonebot.js CHANGED
@@ -19101,7 +19101,7 @@ class OB11HeartbeatEvent extends OB11BaseMetaEvent {
19101
19101
  };
19102
19102
  }
19103
19103
  }
19104
- const version$1 = "7.0.0";
19104
+ const version$1 = "7.0.1";
19105
19105
  class OB11WebSocket {
19106
19106
  constructor(ctx, config2) {
19107
19107
  this.ctx = ctx;
@@ -56850,9 +56850,9 @@ async function transformOutgoingMessage(ctx, segments, peerUid, isGroup = false)
56850
56850
  } else if (segment.type === "mention" && isGroup) {
56851
56851
  const memberUin = segment.data.user_id.toString();
56852
56852
  const memberUid = await ctx.ntUserApi.getUidByUin(memberUin, peerUid);
56853
- elements.push(SendElement.at(memberUin, memberUid, 1, ""));
56853
+ elements.push(SendElement.at(memberUin, memberUid, AtType.One, ""));
56854
56854
  } else if (segment.type === "mention_all" && isGroup) {
56855
- elements.push(SendElement.at("", "", 2, "@全体成员"));
56855
+ elements.push(SendElement.at("", "", AtType.All, "@全体成员"));
56856
56856
  } else if (segment.type === "face") {
56857
56857
  elements.push(SendElement.face(+segment.data.face_id));
56858
56858
  } else if (segment.type === "reply") {
@@ -57564,7 +57564,11 @@ const GetResourceTempUrl = defineApi(
57564
57564
  GetResourceTempUrlOutput,
57565
57565
  async (ctx, payload) => {
57566
57566
  const buffer2 = Buffer.from(payload.resource_id, "base64url");
57567
- const { appid } = RichMedia.FileIdInfo.decode(buffer2);
57567
+ let appid;
57568
+ try {
57569
+ appid = RichMedia.FileIdInfo.decode(buffer2).appid;
57570
+ } catch {
57571
+ }
57568
57572
  if (appid === 1406 || appid === 1407) {
57569
57573
  const rkeyData = await ctx.ntFileApi.rkeyManager.getRkey();
57570
57574
  const rkey = appid === 1406 ? rkeyData.private_rkey : rkeyData.group_rkey;