Commits

Kazunori Ninomiya committed 1b41b52

bug fix.

  • Participants
  • Parent commits bf82a8b

Comments (0)

Files changed (1)

         break;
 
       case 'string':
-        if (typeof file.cwd === 'undefined') {
+        if (typeof orig.cwd === 'undefined') {
           orig.cwd = root;
-          src = grunt.task.normalizeMultiTaskFiles(orig)[0].src;
-          src = src.map(function(v) {
-            return !grunt.file.doesPathContain(root, v) ?
-              path.join(root, path.sep, v) : v;
+          src = grunt.task.normalizeMultiTaskFiles(orig).map(function(v) {
+            return v.src.map(function(v) {
+              return !grunt.file.doesPathContain(root, v) ?
+                path.join(root, path.sep, v) : v;
+            });
           });
+          src = Array.prototype.concat.apply([], src);
         }
         /* falls through */
       default: