File tree 1 file changed +11
-11
lines changed 1 file changed +11
-11
lines changed Original file line number Diff line number Diff line change @@ -1018,17 +1018,17 @@ const posix = {
1018
1018
let resolvedAbsolute = false ;
1019
1019
1020
1020
for ( let i = args . length - 1 ; i >= - 1 && ! resolvedAbsolute ; i -- ) {
1021
- const path = i >= 0 ?
1022
- args [ i ] :
1023
- ( ( ) => {
1024
- const _ = StringPrototypeReplace (
1025
- process . cwd ( ) ,
1026
- new RegExp ( `\\ ${ module . exports . sep } ` , 'g' ) ,
1027
- posix . sep
1028
- ) ;
1029
- return StringPrototypeSlice ( _ , StringPrototypeIndexOf ( _ , posix . sep ) ) ;
1030
- } ) ( ) ;
1031
-
1021
+ let path ;
1022
+ if ( i >= 0 ) {
1023
+ path = args [ i ] ;
1024
+ } else {
1025
+ const _ = StringPrototypeReplace (
1026
+ process . cwd ( ) ,
1027
+ new RegExp ( `\\ ${ module . exports . sep } ` , 'g' ) ,
1028
+ posix . sep
1029
+ ) ;
1030
+ path = StringPrototypeSlice ( _ , StringPrototypeIndexOf ( _ , posix . sep ) ) ;
1031
+ }
1032
1032
1033
1033
validateString ( path , 'path' ) ;
1034
1034
You can’t perform that action at this time.
0 commit comments