Check in case returned error is a string. Ref GH-52.

This commit is contained in:
Kyle Robinson Young 2013-02-25 10:53:33 -08:00
parent 165df7827b
commit 9396cb4e33

View File

@ -97,7 +97,10 @@ module.exports = function(grunt) {
});
// On watcher error
this.on('error', function(err) { grunt.log.error(err); });
this.on('error', function(err) {
if (typeof err === 'string') { err = new Error(err); }
grunt.log.error(err.message);
});
});
});