We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 349d2ed commit 3300d59Copy full SHA for 3300d59
lib/os.js
@@ -180,12 +180,13 @@ platform[SymbolToPrimitive] = () => process.platform;
180
*/
181
function tmpdir() {
182
if (isWindows) {
183
- let path = process.env.TEMP ||
+ const path = process.env.TEMP ||
184
process.env.TMP ||
185
(process.env.SystemRoot || process.env.windir) + '\\temp';
186
+
187
if (path.length > 1 && StringPrototypeEndsWith(path, '\\') &&
188
!StringPrototypeEndsWith(path, ':\\'))
- path = StringPrototypeSlice(path, 0, -1);
189
+ return StringPrototypeSlice(path, 0, -1);
190
191
return path;
192
}
0 commit comments