Skip to content

Commit

Permalink
Make the check for valid files actually work.
Browse files Browse the repository at this point in the history
  • Loading branch information
XhmikosR committed Feb 18, 2015
1 parent cbe19a2 commit 72ee45e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tasks/uglify.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ module.exports = function(grunt) {

// Iterate over all src-dest file pairs.
this.files.forEach(function (f) {
var src = f.src.filter(function (filepath) {
var src = f.orig.src.filter(function (filepath) {
// Warn on and remove invalid source files (if nonull was set).
if (!grunt.file.exists(filepath)) {
grunt.log.warn('Source file ' + chalk.cyan(filepath) + ' not found.');
Expand Down

1 comment on commit 72ee45e

@XhmikosR
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sindresorhus: how about this approach? If one file or more files are missing now it will show:

Running "uglify:minify" (uglify) task
>> Source file src/htmlparser.js not found.
>> 1 file created.

Done, without errors.

Please sign in to comment.