opts is undefined
eplouhinec opened this issue · 3 comments
eplouhinec commented
Hi!
Since last release 1.0.5, I have an issue with opts:
/.../node_modules/gulp-base64-inline/index.js:52
if (opts.prefix !== undefined)
^
TypeError: Cannot read property 'prefix' of undefined
Seems that opts became mandatory since add of opts feature.
For example, first example of readme do not work I think.
It should be:
var gulp = require('gulp');
var base64 = require('gulp-base64-inline');
gulp.task('css', function () {
return gulp.src('css/style.css')
.pipe(base64('../assets/img', {}))
.pipe(gulp.dest('assets/css/'));
}
);
Otherwise, check if props is undefined before trying to find something in it.
goschevski commented
@inuris could you please take a look?
inuris commented
Sorry, I forgot to check the definition of the object opts. I have tested all cases now.
goschevski commented
@eplouhinec fixed and published in v1.0.6
@inuris Thanks!