koishi-plugin-cfmrmod 1.1.6 → 1.1.7

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.
Files changed (2) hide show
  1. package/dist/notify.js +0 -6
  2. package/package.json +1 -1
package/dist/notify.js CHANGED
@@ -252,13 +252,10 @@ function apply(ctx, config, options) {
252
252
  const content = await fs_1.promises.readFile(filePath, 'utf8');
253
253
  const json = JSON.parse(content);
254
254
  if (json && typeof json === 'object') {
255
- // 从文件加载时同步到 config 对象
256
255
  if (typeof json.enabled === 'boolean')
257
256
  config.enabled = json.enabled;
258
257
  if (Array.isArray(json.groups))
259
258
  config.groups = json.groups;
260
- // 更新到 Koishi 配置系统
261
- ctx.scope.update(config, false); // 不重载插件
262
259
  }
263
260
  if (!Array.isArray(config.groups))
264
261
  config.groups = [];
@@ -275,9 +272,6 @@ function apply(ctx, config, options) {
275
272
  // 确保 groups 数组存在
276
273
  if (!Array.isArray(config.groups))
277
274
  config.groups = [];
278
- // 更新到 Koishi 配置系统,让修改反映到配置界面
279
- ctx.scope.update(config, false); // 不重载插件,避免中断运行
280
- // 同时保存到文件,保持 Koishi 配置和文件同步
281
275
  const filePath = resolveConfigFile();
282
276
  await fs_1.promises.mkdir(path_1.default.dirname(filePath), { recursive: true });
283
277
  const obj = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "koishi-plugin-cfmrmod",
3
- "version": "1.1.6",
3
+ "version": "1.1.7",
4
4
  "description": "Koishi 插件:搜索 CurseForge/Modrinth/MCMod 并渲染图片卡片",
5
5
  "main": "dist/index.js",
6
6
  "files": [