oicq-icalingua-plus-plus 1.26.8 → 1.26.9

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/client-ext.js CHANGED
@@ -232,7 +232,7 @@ Client.prototype.buildSyncCookie = function () {
232
232
  * 消息同步
233
233
  */
234
234
  Client.prototype.pbGetMsg = async function (force = false, flag = 0, count = 10) {
235
- if (this.config.useNT && !force) return true;
235
+ if (this.config.useNT) return true;
236
236
  if (count <= 0) {
237
237
  this.sync_cookie = null;
238
238
  return true;
package/lib/oicq.js CHANGED
@@ -394,8 +394,8 @@ async function parseSSO(buf) {
394
394
  const headlen = buf.readInt32BE();
395
395
  const seq = header.read(4).readInt32BE();
396
396
  const retcode = header.read(4).readInt32BE();
397
+ const retmsg = String(header.readWithLength());
397
398
  if (retcode !== 0) {
398
- const retmsg = String(header.readWithLength());
399
399
  const error = new Error("unsuccessful retcode: " + retcode + " retmsg: " + retmsg + " seq: " + seq);
400
400
  if (this.handlers.has(seq))
401
401
  this.handlers.get(seq)(null, error);
package/lib/onlinepush.js CHANGED
@@ -800,8 +800,46 @@ async function NTMsgListener(blob, seq, sso) {
800
800
  }
801
801
  break;
802
802
  case 33: //群员入群
803
+ const group_id = uin2code(o[1][1][1]);
804
+ const msg = o[1][3][2];
805
+ const user_uid = String(msg[3]);
806
+ const user_id = await uid2uin.call(this, user_uid);
807
+ let nickname = "";
808
+ const ginfo = (await this.getGroupInfo(group_id)).data;
809
+ if (!ginfo) return;
810
+ if (user_id === this.uin) {
811
+ nickname = this.nickname;
812
+ this.logger.info(`更新了群列表,新增了群:${group_id}`);
813
+ } else {
814
+ ginfo.member_count++;
815
+ ginfo.last_join_time = timestamp();
816
+ const info = await this.getGroupMemberInfo(group_id, user_id);
817
+ nickname = info.data.nickname || info.data.card || "";
818
+ try {
819
+ if (this.gml.get(group_id).size)
820
+ ginfo.member_count = this.gml.get(group_id).size;
821
+ } catch { }
822
+ this.logger.info(`${user_id}(${nickname}) 加入了群 ${group_id}`);
823
+ }
824
+ this.getGroupMemberList(group_id, true);
825
+ this.em("notice.group.increase", {
826
+ group_id, user_id, nickname
827
+ });
828
+ break;
803
829
  case 38: //建群
804
830
  case 85: //群申请被同意
831
+ const group_id = uin2code(o[1][1][1]);
832
+ const user_id = this.uin;
833
+ const nickname = this.nickname;
834
+ const ginfo = (await this.getGroupInfo(group_id)).data;
835
+ if (!ginfo) return;
836
+ if (user_id === this.uin) {
837
+ this.logger.info(`更新了群列表,新增了群:${group_id}`);
838
+ this.getGroupMemberList(group_id);
839
+ }
840
+ this.em("notice.group.increase", {
841
+ group_id, user_id, nickname
842
+ });
805
843
  break;
806
844
  case 141: //陌生人
807
845
  case 166: //好友
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "oicq-icalingua-plus-plus",
3
3
  "app_name": "oicq-icalingua-plus-plus",
4
- "version": "1.26.8",
5
- "app_version": "1.26.8",
4
+ "version": "1.26.9",
5
+ "app_version": "1.26.9",
6
6
  "upday": "2026/07/19",
7
7
  "protocol_version": "v11",
8
8
  "description": "oicq(https://github.com/takayama-lily/oicq) v1 for Icalingua++",