Correction du chargement de profils partiels via un chemin relatif au profil parent

This commit is contained in:
wpetit 2016-04-15 17:00:04 +02:00
parent 69cc5a6d39
commit 75391a7219
1 changed files with 3 additions and 2 deletions

View File

@ -26,8 +26,9 @@ exports.load = function(profileUrl, withImports) {
node = item.value.node;
// For each import found, load the partial and "mount" it on the current item
if(node.import) {
Logger.info('Loading import "%s"', path.resolve(node.import));
p = exports.load(node.import)
var importPath = path.resolve(path.dirname(profileUrl), node.import)
Logger.info('Loading import "%s"', importPath);
p = exports.load(importPath)
.then(_mountImport.bind(node))
;
promises.push(p);