Less: Pass error in callback, don't throw

This commit is contained in:
Slava Kim
2015-07-24 14:51:10 -07:00
parent 03087d10cd
commit 1e3b09df8f

View File

@@ -124,7 +124,8 @@ class MeteorImportLessFileManager extends less.AbstractFileManager {
if (! packageMatch) {
// shouldn't happen. all filenames less ever sees should involve this {}
// thing!
throw new Error('file without Meteor context? ' + currentDirectory);
cb(new Error('file without Meteor context? ' + currentDirectory));
return;
}
const currentPackagePrefix = packageMatch[1];