koishi-plugin-ets2-tools-tmp 3.0.1 → 3.0.3

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.
@@ -88,14 +88,17 @@ module.exports = async (ctx, cfg, session, target, changeType, quantity, reason)
88
88
  reason: reason
89
89
  };
90
90
  log(`[V1] 积分修改请求: ${changeUrl}, body: ${JSON.stringify(requestBody)}`);
91
- const changeResponse = await ctx.http.post(changeUrl, requestBody, { timeout: 10000 });
91
+ const changeResponse = await ctx.http.post(changeUrl, requestBody, {
92
+ timeout: 10000,
93
+ headers: { "Content-Type": "application/json", token }
94
+ });
92
95
  log(`[V1] 积分修改响应: ${JSON.stringify(changeResponse)}`);
93
96
 
94
97
  if (changeResponse.code !== 0) {
95
98
  return changeResponse.msg || "积分修改失败";
96
99
  }
97
100
 
98
- return `积分修改成功!\n目标ID: ${userId}\n操作: ${changeType} ${quantityNum} 积分\n备注: ${reason}`;
101
+ return `积分修改成功!\n操作: ${changeType} ${quantityNum} 积分`;
99
102
 
100
103
  } catch (error) {
101
104
  ctx.logger.error(`[V1] 积分修改错误: ${error.message}`);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "koishi-plugin-ets2-tools-tmp",
3
3
  "description": "欧卡2 TruckersMP信息查询、车队平台查询及活动提醒",
4
- "version": "3.0.1",
4
+ "version": "3.0.3",
5
5
  "contributors": [
6
6
  "opwop <slhp1013@qq.com>",
7
7
  "bot_actions <168329908@qq.com>"