gulp-dynamic
Advanced tools
Comparing version 1.0.1 to 1.1.0
18
index.js
@@ -13,4 +13,16 @@ var evs = require('event-stream'); | ||
if (file.isBuffer()) { | ||
file.contents = new Buffer(dynamic(file.path, String(file.contents), opt)); | ||
try { | ||
if (file.isBuffer()) { | ||
file.contents = new Buffer(dynamic(file.path, String(file.contents), opt)); | ||
} | ||
} catch (e) { | ||
console.error(e); | ||
this.emit('error', new g_util.PluginError({ | ||
plugin: 'gulp-dynamic', | ||
message: e | ||
})); | ||
} | ||
@@ -22,2 +34,2 @@ | ||
return evs.through(processImports); | ||
}; | ||
}; |
@@ -15,3 +15,3 @@ { | ||
], | ||
"version": "1.0.1", | ||
"version": "1.1.0", | ||
"dependencies": { | ||
@@ -18,0 +18,0 @@ "gulp-util": "~3.0.0", |
Sorry, the diff of this file is not supported yet
3821
23