onebots 0.0.27 → 0.0.29

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/bin.js CHANGED
@@ -7,5 +7,4 @@ const obj = {};
7
7
  for (let i = 0; i < execArgv.length; i += 2) {
8
8
  obj[execArgv[i]] = execArgv[i + 1];
9
9
  }
10
- console.log(obj);
11
10
  (0, app_1.createApp)(obj['-c']).start();
@@ -340,7 +340,7 @@ class V12 extends events_1.EventEmitter {
340
340
  action = "send_" + params.detail_type + "_msg";
341
341
  }
342
342
  else if (params.user_id)
343
- action = "send_private_msg";
343
+ action = "send_Private_Msg";
344
344
  else if (params.group_id)
345
345
  action = "send_group_msg";
346
346
  else if (params.discuss_id)
@@ -364,7 +364,6 @@ class V12 extends events_1.EventEmitter {
364
364
  params[k] = (0, utils_1.toBool)(params[k]);
365
365
  if (k === 'message') {
366
366
  params[k] = V12.fromSegment(params[k]);
367
- console.log(params[k]);
368
367
  params['message_id'] = params[k].find(e => e.type === 'reply')?.message_id;
369
368
  }
370
369
  args.push(params[k]);
@@ -570,9 +569,10 @@ exports.V12 = V12;
570
569
  return { type: 'text', text: msg };
571
570
  }
572
571
  const { type, data, ...other } = msg;
572
+ if (type === 'mention')
573
+ data['qq'] = Number(data['user_id']);
573
574
  return {
574
575
  type: type.replace('mention', 'at').replace('at_all', 'at'),
575
- qq: data['user_id'],
576
576
  ...other,
577
577
  ...data
578
578
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "onebots",
3
- "version": "0.0.27",
3
+ "version": "0.0.29",
4
4
  "description": "基于oicq的多例oneBot实现",
5
5
  "engines": {
6
6
  "node": ">=16"