From 839df5170a82cfa0cc29c1ba277db6be6cc8f63e Mon Sep 17 00:00:00 2001 From: Jerryplusy Date: Mon, 25 Aug 2025 23:09:51 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E6=A1=88=E6=A8=A1=E5=9D=97=E4=BC=98?= =?UTF-8?q?=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/modules/words/words.module.ts | 3 ++- src/modules/words/words.service.ts | 3 +-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/modules/words/words.module.ts b/src/modules/words/words.module.ts index 78c95fd..98e69ec 100644 --- a/src/modules/words/words.module.ts +++ b/src/modules/words/words.module.ts @@ -3,9 +3,10 @@ import { WordsController } from './words.controller'; import { WordsService } from './words.service'; import { PathModule } from '../../core/path/path.module'; import { ToolsModule } from '../../core/tools/tools.module'; +import { AutoUpdateModule } from '../../core/auto-update/auto-update.module'; @Module({ - imports: [PathModule, ToolsModule], + imports: [PathModule, ToolsModule, AutoUpdateModule], controllers: [WordsController], providers: [WordsService], exports: [WordsService], diff --git a/src/modules/words/words.service.ts b/src/modules/words/words.service.ts index 4ca9522..0d69959 100644 --- a/src/modules/words/words.service.ts +++ b/src/modules/words/words.service.ts @@ -35,9 +35,8 @@ export class WordsService { * 启动定时检查 words 仓库更新 */ private startAutoUpdate() { - const wordsPath = this.paths.get('words'); - setInterval(async () => { + const wordsPath = this.paths.get('words'); this.logger.log('定时检查文案仓库更新..'); const updated = await this.autoUpdateService.checkRepoForUpdates( wordsPath,