koishi-plugin-bilibili-notify 2.0.0-alpha.19 → 2.0.0-alpha.20

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.
@@ -1082,13 +1082,12 @@ class ComRegister {
1082
1082
  // 推送直播信息
1083
1083
  // pic 存在,使用的是render模式
1084
1084
  if (pic) {
1085
- const msg = liveNotifyMsg || '';
1086
1085
  // 只有在开播时才艾特全体成员
1087
1086
  if (liveType === LiveType.StartBroadcasting) {
1088
- return await this.sendMsg(ctx, target, pic + msg, true);
1087
+ return await this.sendMsg(ctx, target, pic + (liveNotifyMsg ?? ''), true);
1089
1088
  }
1090
1089
  // 正常不需要艾特全体成员
1091
- return await this.sendMsg(ctx, target, pic + msg);
1090
+ return await this.sendMsg(ctx, target, pic + (liveNotifyMsg ?? ''));
1092
1091
  }
1093
1092
  // pic不存在,说明使用的是page模式
1094
1093
  const msg = (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [koishi_1.h.image(buffer, 'image/png'), liveNotifyMsg || ''] });
@@ -1169,7 +1168,7 @@ class ComRegister {
1169
1168
  const liveMsg = this.config.customLive ? this.config.customLive
1170
1169
  .replace('-name', username)
1171
1170
  .replace('-time', await ctx.gi.getTimeDifference(liveTime))
1172
- .replace('-link', `https://live.bilibili.com/${data.short_id === 0 ? data.room_id : data.short_id}`) : '';
1171
+ .replace('-link', `https://live.bilibili.com/${data.short_id === 0 ? data.room_id : data.short_id}`) : null;
1173
1172
  // 发送直播通知卡片
1174
1173
  if (this.config.restartPush)
1175
1174
  sendLiveNotifyCard(data, LiveType.LiveBroadcast, liveMsg);
@@ -1242,7 +1241,7 @@ class ComRegister {
1242
1241
  const liveMsg = this.config.customLive ? this.config.customLive
1243
1242
  .replace('-name', username)
1244
1243
  .replace('-time', await ctx.gi.getTimeDifference(liveTime))
1245
- .replace('-link', `https://live.bilibili.com/${data.short_id === 0 ? data.room_id : data.short_id}`) : '';
1244
+ .replace('-link', `https://live.bilibili.com/${data.short_id === 0 ? data.room_id : data.short_id}`) : null;
1246
1245
  // 发送直播通知卡片
1247
1246
  sendLiveNotifyCard(data, LiveType.LiveBroadcast, liveMsg);
1248
1247
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "koishi-plugin-bilibili-notify",
3
3
  "description": "Koishi bilibili notify plugin",
4
- "version": "2.0.0-alpha.19",
4
+ "version": "2.0.0-alpha.20",
5
5
  "contributors": [
6
6
  "Akokko <admin@akokko.com>"
7
7
  ],
package/readme.md CHANGED
@@ -206,6 +206,7 @@
206
206
  - ver 2.0.0-alpha.17 修复:直接订阅当前环境不会推送
207
207
  - ver 2.0.0-alpha.18 修复:手动订阅无法推送直播通知;自定义直播中通知语不会发送
208
208
  - ver 2.0.0-alpha.19 修复:开播通知后带false;下播通知卡片人气位置显示false
209
+ - ver 2.0.0-alpha.20 修复:直播推送失败 `Error with request send_group_msg`
209
210
 
210
211
  ## 交流群
211
212