File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -239,7 +239,7 @@ var Project = function () {
239
239
var CLIEngine = require ( 'eslint' ) . CLIEngine ;
240
240
241
241
// 如果有本地eslint优先使用本地eslint
242
- if ( requireg ( sysPath . join ( this . cwd , 'node_modules/' , 'eslint' ) ) ) {
242
+ if ( requireg . resolve ( sysPath . join ( this . cwd , 'node_modules/' , 'eslint' ) ) ) {
243
243
CLIEngine = requireg ( sysPath . join ( this . cwd , 'node_modules/' , 'eslint' ) ) . CLIEngine ;
244
244
}
245
245
Original file line number Diff line number Diff line change @@ -212,7 +212,7 @@ class Project {
212
212
let CLIEngine = require ( 'eslint' ) . CLIEngine ;
213
213
214
214
// 如果有本地eslint优先使用本地eslint
215
- if ( requireg ( sysPath . join ( this . cwd , 'node_modules/' , 'eslint' ) ) ) {
215
+ if ( requireg . resolve ( sysPath . join ( this . cwd , 'node_modules/' , 'eslint' ) ) ) {
216
216
CLIEngine = requireg ( sysPath . join ( this . cwd , 'node_modules/' , 'eslint' ) ) . CLIEngine
217
217
}
218
218
You can’t perform that action at this time.
0 commit comments