Pass along file when .isNull()
This commit is contained in:
parent
f6af95634d
commit
52e7d845ee
10
index.js
10
index.js
|
@ -15,7 +15,7 @@ module.exports = function (options) {
|
|||
}
|
||||
|
||||
if (file.isNull()) {
|
||||
return cb();
|
||||
return cb(null, file);
|
||||
}
|
||||
|
||||
opts.data = file.contents.toString();
|
||||
|
@ -25,18 +25,18 @@ module.exports = function (options) {
|
|||
file.shortened = file.shortened && ext(file.shortened, '.css');
|
||||
file.contents = new Buffer(css);
|
||||
cb(null, file);
|
||||
}
|
||||
};
|
||||
|
||||
opts.error = function (err) {
|
||||
if (opts.errLogToConsole) {
|
||||
gutil.log('[gulp-sass] ' + err)
|
||||
gutil.log('[gulp-sass] ' + err);
|
||||
return cb();
|
||||
}
|
||||
return cb(new gutil.PluginError('gulp-sass', err));
|
||||
}
|
||||
};
|
||||
|
||||
sass.render(opts);
|
||||
}
|
||||
|
||||
return es.map(nodeSass);
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue