Skip to content

Commit

Permalink
used StringPrototypeSlice
Browse files Browse the repository at this point in the history
  • Loading branch information
Mert Can Altin authored and Mert Can Altin committed Oct 17, 2024
1 parent 1d4011d commit b7d37d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/os.js
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ function tmpdir() {

if (path.length > 1 && path[path.length - 1] === '\\' &&
!(path.length > 2 && path[path.length - 2] === ':' && path[path.length - 1] === '\\')) {
return path.slice(0, -1);
return StringPrototypeSlice(path, 0, -1);
}


Expand Down

0 comments on commit b7d37d3

Please sign in to comment.