|
|
@@ -29,17 +29,14 @@ module.exports.getGlobbedFiles = function(globPatterns, removeRoot) {
|
|
|
if (urlRegex.test(globPatterns)) {
|
|
|
output.push(globPatterns);
|
|
|
} else {
|
|
|
- glob(globPatterns, {
|
|
|
- sync: true
|
|
|
- }, function(err, files) {
|
|
|
- if (removeRoot) {
|
|
|
- files = files.map(function(file) {
|
|
|
- return file.replace(removeRoot, '');
|
|
|
- });
|
|
|
- }
|
|
|
-
|
|
|
- output = _.union(output, files);
|
|
|
- });
|
|
|
+ var files = glob.sync(globPatterns);
|
|
|
+ if (removeRoot) {
|
|
|
+ files = files.map(function(file) {
|
|
|
+ return file.replace(removeRoot, '');
|
|
|
+ });
|
|
|
+ }
|
|
|
+
|
|
|
+ output = _.union(output, files);
|
|
|
}
|
|
|
}
|
|
|
|