We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc903b4 commit d696940Copy full SHA for d696940
myFetch.js
@@ -3,6 +3,7 @@
3
const os = require('os');
4
var path = require('path');
5
var fs = require('fs');
6
+var { sep } = require('path');
7
8
function getFetcher(u) {
9
if(u.protocol === 'https:') return require('https');
@@ -29,7 +30,7 @@ function myFetch(fullUrl) {
29
30
} else if(res.statusCode !== 200) {
31
return reject(Error(`Bad status code ${res.statusCode}`));
32
}
- const tmpd = fs.mkdtempSync(os.tmpdir());
33
+ const tmpd = fs.mkdtempSync(`${os.tmpdir()}${sep}`);
34
const tmpf = path.join(tmpd, 'icu-download.zip');
35
let gotSoFar = 0;
36
console.dir(tmpd);
@@ -55,4 +56,4 @@ function myFetch(fullUrl) {
55
56
});
57
58
-module.exports = myFetch;
59
+module.exports = myFetch;
0 commit comments