Skip to content

Commit 568b13b

Browse files
authored
Merge pull request dlmanning#509 from xzyfer/fix/option-leakage
Prevent options leaking between compilations
2 parents 05f4cdf + 035b759 commit 568b13b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
var gutil = require('gulp-util');
44
var through = require('through2');
5-
var assign = require('object-assign');
5+
var clonedeep = require('lodash.clonedeep');
66
var path = require('path');
77
var applySourceMap = require('vinyl-sourcemaps-apply');
88

@@ -34,7 +34,7 @@ var gulpSass = function gulpSass(options, sync) {
3434
}
3535

3636

37-
opts = assign({}, options);
37+
opts = clonedeep(options || {});
3838
opts.data = file.contents.toString();
3939

4040
// we set the file path here so that libsass can correctly resolve import paths

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@
2222
},
2323
"dependencies": {
2424
"gulp-util": "^3.0",
25+
"lodash.clonedeep": "^4.3.2",
2526
"node-sass": "^3.4.2",
26-
"object-assign": "^4.0.1",
2727
"through2": "^2.0.0",
2828
"vinyl-sourcemaps-apply": "^0.2.0"
2929
},

0 commit comments

Comments
 (0)