From e6474a16b8dec9829acb2832f703d6c34defc93b Mon Sep 17 00:00:00 2001 From: Baoshuo Date: Thu, 9 Mar 2023 06:59:58 +0800 Subject: [PATCH] fix: lint errors --- lib/hexo/index.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/hexo/index.ts b/lib/hexo/index.ts index 63d3a77070..f1d11e99d4 100644 --- a/lib/hexo/index.ts +++ b/lib/hexo/index.ts @@ -121,8 +121,8 @@ interface Query { declare module 'module' { function _nodeModulePaths(path: string): string[]; function _resolveFilename(request: string, parent: Module, isMain?: any, options?: any): string; - const _extensions: NodeJS.RequireExtensions; - const _cache: any; + const _extensions: NodeJS.RequireExtensions, + _cache: any; } class Hexo extends EventEmitter { @@ -351,7 +351,7 @@ class Hexo extends EventEmitter { } } - loadPlugin(path: string, callback: Function) { + loadPlugin(path: string, callback: (...args: any[]) => any) { return readFile(path).then(script => { // Based on: https://github.com/joyent/node/blob/v0.10.33/src/node.js#L516 const module = new Module(path);