Skip to content

Commit

Permalink
Merge pull request #19 from ksky521/patch-2
Browse files Browse the repository at this point in the history
Update index.js
  • Loading branch information
2betop committed Mar 26, 2015
2 parents c20940e + baca57b commit 01b650a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,10 @@ module.exports = function(content, file, conf){
if (file.cache) {
file.cache.addDeps(target.realpath);
}

//解决include_path 内import导致subpath为空报错问题
if(!target.subpath){
target.subpath = path.relative(root, target.realpath);
}
~sources.indexOf(target.subpath) || sources.push(target.subpath);

done({
Expand Down

0 comments on commit 01b650a

Please sign in to comment.