koishi-plugin-bilibili-notify 3.2.5-alpha.12 → 3.2.5-alpha.13
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/lib/index.js +8 -4
- package/lib/index.mjs +8 -4
- package/package.json +1 -1
- package/readme.md +1 -0
package/lib/index.js
CHANGED
|
@@ -834,29 +834,33 @@ var ComRegister = class {
|
|
|
834
834
|
this.logger.info("本次推送目标:");
|
|
835
835
|
if (type === PushType.StartBroadcasting && record.atAllArr?.length >= 1) {
|
|
836
836
|
this.logger.info(record.atAllArr);
|
|
837
|
+
const atAllArr = structuredClone(record.atAllArr);
|
|
837
838
|
const success = await withRetry(async () => {
|
|
838
|
-
return await this.ctx.broadcast(
|
|
839
|
+
return await this.ctx.broadcast(atAllArr, /* @__PURE__ */ (0, __satorijs_element_jsx_runtime.jsx)("message", { children: /* @__PURE__ */ (0, __satorijs_element_jsx_runtime.jsx)("at", { type: "all" }) }));
|
|
839
840
|
}, 1);
|
|
840
841
|
this.logger.info(`成功推送全体成员消息群组/频道:${success}`);
|
|
841
842
|
}
|
|
842
843
|
if (type === PushType.Dynamic && record.dynamicArr?.length >= 1) {
|
|
843
844
|
this.logger.info(record.dynamicArr);
|
|
845
|
+
const dynamicArr = structuredClone(record.dynamicArr);
|
|
844
846
|
const success = await withRetry(async () => {
|
|
845
|
-
return await this.ctx.broadcast(
|
|
847
|
+
return await this.ctx.broadcast(dynamicArr, /* @__PURE__ */ (0, __satorijs_element_jsx_runtime.jsx)("message", { children: content }));
|
|
846
848
|
}, 1);
|
|
847
849
|
this.logger.info(`成功推送动态消息群组/频道:${success}`);
|
|
848
850
|
}
|
|
849
851
|
if ((type === PushType.Live || type === PushType.StartBroadcasting) && record.liveArr?.length >= 1) {
|
|
850
852
|
this.logger.info(record.liveArr);
|
|
853
|
+
const liveArr = structuredClone(record.liveArr);
|
|
851
854
|
const success = await withRetry(async () => {
|
|
852
|
-
return await this.ctx.broadcast(
|
|
855
|
+
return await this.ctx.broadcast(liveArr, /* @__PURE__ */ (0, __satorijs_element_jsx_runtime.jsx)("message", { children: content }));
|
|
853
856
|
}, 1);
|
|
854
857
|
this.logger.info(`成功推送直播消息群组/频道:${success}`);
|
|
855
858
|
}
|
|
856
859
|
if (type === PushType.LiveGuardBuy && record.liveGuardBuyArr?.length >= 1) {
|
|
857
860
|
this.logger.info(record.liveGuardBuyArr);
|
|
861
|
+
const liveGuardBuyArr = structuredClone(record.liveGuardBuyArr);
|
|
858
862
|
const success = await withRetry(async () => {
|
|
859
|
-
return await this.ctx.broadcast(
|
|
863
|
+
return await this.ctx.broadcast(liveGuardBuyArr, /* @__PURE__ */ (0, __satorijs_element_jsx_runtime.jsx)("message", { children: content }));
|
|
860
864
|
}, 1);
|
|
861
865
|
this.logger.info(`成功推送上舰消息群组/频道:${success}`);
|
|
862
866
|
}
|
package/lib/index.mjs
CHANGED
|
@@ -836,29 +836,33 @@ var ComRegister = class {
|
|
|
836
836
|
this.logger.info("本次推送目标:");
|
|
837
837
|
if (type === PushType.StartBroadcasting && record.atAllArr?.length >= 1) {
|
|
838
838
|
this.logger.info(record.atAllArr);
|
|
839
|
+
const atAllArr = structuredClone(record.atAllArr);
|
|
839
840
|
const success = await withRetry(async () => {
|
|
840
|
-
return await this.ctx.broadcast(
|
|
841
|
+
return await this.ctx.broadcast(atAllArr, /* @__PURE__ */ jsx("message", { children: /* @__PURE__ */ jsx("at", { type: "all" }) }));
|
|
841
842
|
}, 1);
|
|
842
843
|
this.logger.info(`成功推送全体成员消息群组/频道:${success}`);
|
|
843
844
|
}
|
|
844
845
|
if (type === PushType.Dynamic && record.dynamicArr?.length >= 1) {
|
|
845
846
|
this.logger.info(record.dynamicArr);
|
|
847
|
+
const dynamicArr = structuredClone(record.dynamicArr);
|
|
846
848
|
const success = await withRetry(async () => {
|
|
847
|
-
return await this.ctx.broadcast(
|
|
849
|
+
return await this.ctx.broadcast(dynamicArr, /* @__PURE__ */ jsx("message", { children: content }));
|
|
848
850
|
}, 1);
|
|
849
851
|
this.logger.info(`成功推送动态消息群组/频道:${success}`);
|
|
850
852
|
}
|
|
851
853
|
if ((type === PushType.Live || type === PushType.StartBroadcasting) && record.liveArr?.length >= 1) {
|
|
852
854
|
this.logger.info(record.liveArr);
|
|
855
|
+
const liveArr = structuredClone(record.liveArr);
|
|
853
856
|
const success = await withRetry(async () => {
|
|
854
|
-
return await this.ctx.broadcast(
|
|
857
|
+
return await this.ctx.broadcast(liveArr, /* @__PURE__ */ jsx("message", { children: content }));
|
|
855
858
|
}, 1);
|
|
856
859
|
this.logger.info(`成功推送直播消息群组/频道:${success}`);
|
|
857
860
|
}
|
|
858
861
|
if (type === PushType.LiveGuardBuy && record.liveGuardBuyArr?.length >= 1) {
|
|
859
862
|
this.logger.info(record.liveGuardBuyArr);
|
|
863
|
+
const liveGuardBuyArr = structuredClone(record.liveGuardBuyArr);
|
|
860
864
|
const success = await withRetry(async () => {
|
|
861
|
-
return await this.ctx.broadcast(
|
|
865
|
+
return await this.ctx.broadcast(liveGuardBuyArr, /* @__PURE__ */ jsx("message", { children: content }));
|
|
862
866
|
}, 1);
|
|
863
867
|
this.logger.info(`成功推送上舰消息群组/频道:${success}`);
|
|
864
868
|
}
|
package/package.json
CHANGED