@alemonjs/qq-bot 2.1.0-alpha.18 → 2.1.0-alpha.19

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 CHANGED
@@ -22,12 +22,12 @@ const main = () => {
22
22
  const mainProcess = () => {
23
23
  ['SIGINT', 'SIGTERM', 'SIGQUIT', 'disconnect'].forEach(sig => {
24
24
  process?.on?.(sig, () => {
25
- logger?.info?.(`[alemonjs][${sig}] 收到信号,正在关闭...`);
25
+ logger?.info?.(`[@alemonjs/qq-bot][${sig}] 收到信号,正在关闭...`);
26
26
  setImmediate(() => process.exit(0));
27
27
  });
28
28
  });
29
29
  process?.on?.('exit', code => {
30
- logger?.info?.(`[alemonjs][exit] 进程退出,code=${code}`);
30
+ logger?.info?.(`[@alemonjs/qq-bot][exit] 进程退出,code=${code}`);
31
31
  });
32
32
  // 监听主进程消息
33
33
  process.on('message', msg => {
@@ -69,7 +69,7 @@ const filterRequest = (request = {}) => {
69
69
  return filtered;
70
70
  };
71
71
  // 处理axios错误
72
- const loggerError = (err) => {
72
+ const loggerError = err => {
73
73
  // 错误时的请求头
74
74
  logger.error('[axios] error', {
75
75
  config: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alemonjs/qq-bot",
3
- "version": "2.1.0-alpha.18",
3
+ "version": "2.1.0-alpha.19",
4
4
  "description": "阿柠檬qqbot平台连接",
5
5
  "author": "lemonade",
6
6
  "license": "MIT",
@@ -32,7 +32,8 @@
32
32
  "exports": {
33
33
  ".": {
34
34
  "import": "./lib/index.js",
35
- "types": "./lib/index.d.ts"
35
+ "types": "./lib/index.d.ts",
36
+ "require": "./lib/index.js"
36
37
  },
37
38
  "./package": "./package.json",
38
39
  "./desktop": "./lib/desktop.js"