File tree Expand file tree Collapse file tree 2 files changed +6
-2
lines changed
metascraper-clearbit-logo Expand file tree Collapse file tree 2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 38
38
],
39
39
"scripts" : {
40
40
"coveralls" : " nyc report --reporter=text-lcov | coveralls" ,
41
- "test" : " TZ=UTC NODE_ENV=test nyc mocha test"
41
+ "test" : " NODE_PATH=.. TZ=UTC NODE_ENV=test nyc mocha test"
42
42
},
43
43
"license" : " MIT" ,
44
44
"lint-staged" : {
Original file line number Diff line number Diff line change 1
1
'use strict'
2
2
3
+ const path = require ( 'path' )
4
+
3
5
const cwd = process . env . METASCRAPER_CONFIG_CWD || process . cwd ( )
4
6
const config = require ( 'cosmiconfig' ) ( 'metascraper' ) . load ( cwd )
7
+
5
8
const {
6
9
findIndex,
7
10
forEach,
@@ -45,7 +48,8 @@ module.exports = () =>
45
48
moduleConfig = rule [ moduleName ]
46
49
}
47
50
48
- return require ( moduleName ) ( moduleConfig )
51
+ const modulePath = path . resolve ( cwd , 'node_modules' , moduleName )
52
+ return require ( modulePath ) ( moduleConfig )
49
53
} )
50
54
// merge rules with same props
51
55
. reduce ( ( acc , rules ) => {
You can’t perform that action at this time.
0 commit comments