Skip to content

Commit

Permalink
Merge pull request #3170 from thorn0/patch-1
Browse files Browse the repository at this point in the history
`inline` and `less` imports of the same name = race condition
  • Loading branch information
seven-phases-max committed Feb 19, 2018
2 parents 2f1386f + 6985541 commit 3699921
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/less/import-manager.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,10 @@ module.exports = function(environment) {
callback(null, {rules:[]}, false, null);
}
else {
if (!importManager.files[fullPath]) {
// Inline imports aren't cached here.
// If we start to cache them, please make sure they won't conflict with non-inline imports of the
// same name as they used to do before this comment and the condition below have been added.
if (!importManager.files[fullPath] && !importOptions.inline) {
importManager.files[fullPath] = { root: root, options: importOptions };
}
if (e && !importManager.error) { importManager.error = e; }
Expand Down

0 comments on commit 3699921

Please sign in to comment.