Skip to content

Commit

Permalink
fix: Use make-dir instead of mkdirp (#3490)
Browse files Browse the repository at this point in the history
* fix: Use make-dir instead of mkdirp
* Use compatible make-dir version
  • Loading branch information
matthew-dean committed May 5, 2020
1 parent a1862fe commit 9d2ceb9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
8 changes: 6 additions & 2 deletions bin/lessc
Expand Up @@ -156,8 +156,12 @@ function render() {
existsSync = fs.existsSync || path.existsSync;
if (!existsSync(dir)) {
if (mkdirp === undefined) {
try {mkdirp = require('mkdirp');}
catch (e) { mkdirp = null; }
try {
mkdirp = require('make-dir');
}
catch (e) {
mkdirp = null;
}
}
cmd = mkdirp && mkdirp.sync || fs.mkdirSync;
cmd(dir);
Expand Down
3 changes: 2 additions & 1 deletion package.json
Expand Up @@ -45,8 +45,9 @@
"errno": "^0.1.1",
"graceful-fs": "^4.1.2",
"image-size": "~0.5.0",
"make-dir":"^2.1.0",
"mime": "^1.4.1",
"mkdirp": "^0.5.0",
"promise": "^7.1.1",
"request": "^2.83.0",
"source-map": "~0.6.0"
},
Expand Down

0 comments on commit 9d2ceb9

Please sign in to comment.