Skip to content

Commit

Permalink
Refactor path normalizations after merging #141
Browse files Browse the repository at this point in the history
  • Loading branch information
jhnns committed Aug 14, 2015
1 parent 7bab632 commit f90aacc
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,8 @@ module.exports = function (content) {
var dirContext;
var request;

// node-sass returns UNIX-style paths
fileContext = path.normalize(fileContext);
request = utils.urlToRequest(url, opt.root);
dirContext = fileToDirContext(fileContext);

Expand All @@ -91,6 +93,8 @@ module.exports = function (content) {
var dirContext;
var request;

// node-sass returns UNIX-style paths
fileContext = path.normalize(fileContext);
request = utils.urlToRequest(url, opt.root);
dirContext = fileToDirContext(fileContext);

Expand Down Expand Up @@ -237,15 +241,15 @@ module.exports = function (content) {
return result.css.toString();
} catch (err) {
formatSassError(err);
err.file && addNormalizedDependency(err.file);
err.file && this.dependency(err.file);
throw err;
}
}

asyncSassJobQueue.push(opt, function onRender(err, result) {
if (err) {
formatSassError(err);
err.file && addNormalizedDependency(err.file);
err.file && self.dependency(err.file);
callback(err);
return;
}
Expand Down

0 comments on commit f90aacc

Please # to comment.