File tree 1 file changed +6
-8
lines changed
packages/create-react-app
1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change @@ -54,21 +54,19 @@ function isUsingYarn() {
54
54
}
55
55
56
56
function hasGivenWarning ( ) {
57
- const ourPackageInNodeModules = path . join ( 'node_modules' , packageJson . name ) ;
58
- const warningFilePath = path . join (
59
- ourPackageInNodeModules ,
57
+ const localWarningFilePath = path . join (
58
+ __dirname ,
60
59
'given-deprecation-warning'
61
60
) ;
62
- return fs . existsSync ( warningFilePath ) ;
61
+ return fs . existsSync ( localWarningFilePath ) ;
63
62
}
64
63
65
64
function writeWarningFile ( ) {
66
- const ourPackageInNodeModules = path . join ( 'node_modules' , packageJson . name ) ;
67
- const warningFilePath = path . join (
68
- ourPackageInNodeModules ,
65
+ const localWarningFilePath = path . join (
66
+ __dirname ,
69
67
'given-deprecation-warning'
70
68
) ;
71
- fs . writeFileSync ( warningFilePath , 'true' ) ;
69
+ fs . writeFileSync ( localWarningFilePath , 'true' ) ;
72
70
}
73
71
74
72
let projectName ;
You can’t perform that action at this time.
0 commit comments