Skip to content

Commit

Permalink
Making work on Windows by using path.resolve.
Browse files Browse the repository at this point in the history
  • Loading branch information
domenic committed May 1, 2012
1 parent fa94187 commit 7f91b45
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/codex/utils/fs.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,9 @@ exports.mkdir = function (_path, mode, callback) {
_path = path.resolve(_path);

function _mkdir(p, next) {
var _p = path.normalize(p).split('/');

path.exists(p, function (exists) {
if (!exists) {
_mkdir(_p.slice(0, -1).join('/'), function (err) {
_mkdir(path.resolve(p, '..'), function (err) {
if (err) next(err);
fs.mkdir(p, mode, function () {
next(null);
Expand Down

0 comments on commit 7f91b45

Please sign in to comment.