File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ const HANDLEBARS_PATTERN = /\.(hbs|handlebars)$/;
7
7
const JAVASCRIPT_PATTERN = / \. ( j s ) $ / ;
8
8
9
9
const NODE_MODULE_DIRECTORIES = [
10
- path . join ( __dirname , '../ node_modules' ) ,
10
+ path . join ( __dirname , '..' , ' node_modules') ,
11
11
path . join ( process . cwd ( ) , 'node_modules' )
12
12
] ;
13
13
@@ -25,13 +25,13 @@ const NODE_MODULE_DIRECTORIES = [
25
25
const findPackagePath = pkg =>
26
26
Promise . all ( NODE_MODULE_DIRECTORIES . map ( dir => new Promise ( resolve => {
27
27
28
- const path = ` ${ dir } / ${ pkg } ` ;
28
+ const filepath = path . join ( dir , pkg ) ;
29
29
30
- fs . stat ( path , ( err , stats ) => {
30
+ fs . stat ( filepath , ( err , stats ) => {
31
31
32
32
if ( ! err && stats . isDirectory ( ) ) {
33
33
34
- return resolve ( path ) ;
34
+ return resolve ( filepath ) ;
35
35
36
36
}
37
37
Original file line number Diff line number Diff line change @@ -33,11 +33,11 @@ const findPackageFileInPath = input => {
33
33
34
34
if ( stat . isFile ( ) ) {
35
35
36
- return path . resolve ( path . join ( path . dirname ( input ) , '/ package.json' ) ) ;
36
+ return path . resolve ( path . join ( path . dirname ( input ) , 'package.json' ) ) ;
37
37
38
38
} else if ( stat . isDirectory ( ) ) {
39
39
40
- return path . resolve ( path . join ( input , '/ package.json' ) ) ;
40
+ return path . resolve ( path . join ( input , 'package.json' ) ) ;
41
41
42
42
}
43
43
You can’t perform that action at this time.
0 commit comments