Skip to content

Commit b5912a2

Browse files
committed
Breaking: Rename stripBOM option to removeBOM
1 parent 9f69f44 commit b5912a2

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

lib/src/options.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ var config = {
1212
since: {
1313
type: 'date',
1414
},
15-
stripBOM: {
15+
removeBOM: {
1616
type: 'boolean',
1717
default: true,
1818
},

lib/src/read-contents/read-buffer.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ function bufferFile(file, optResolver, onRead) {
1111
return onRead(readErr);
1212
}
1313

14-
var stripBOM = optResolver.resolve('stripBOM', file);
15-
if (stripBOM) {
14+
var removeBOM = optResolver.resolve('removeBOM', file);
15+
if (removeBOM) {
1616
file.contents = removeBomBuffer(data);
1717
} else {
1818
file.contents = data;

lib/src/read-contents/read-stream.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@ function streamFile(file, optResolver, onRead) {
1313

1414
var filePath = file.path;
1515

16-
var stripBOM = optResolver.resolve('stripBOM', file);
16+
var removeBOM = optResolver.resolve('removeBOM', file);
1717

1818
file.contents = new lazystream.Readable(function() {
1919
var contents = fs.createReadStream(filePath);
2020

21-
if (stripBOM) {
21+
if (removeBOM) {
2222
return contents.pipe(removeBomStream());
2323
}
2424

test/src.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ describe('.src()', function() {
152152
}
153153

154154
pipe([
155-
vfs.src(bomInputPath, { stripBOM: false }),
155+
vfs.src(bomInputPath, { removeBOM: false }),
156156
concat(assert),
157157
], done);
158158
});

0 commit comments

Comments
 (0)