Skip to content

Commit 947cd61

Browse files
author
Dimitri Benin
committed
Rename this.seperator to this.separator
1 parent 9457db6 commit 947cd61

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ var stringify = Stringify()
6464
stringify.replacer = function () {}
6565
stringify.space = 2
6666
stringify.opener = '['
67-
stringify.seperator = ','
67+
stringify.separator = ','
6868
stringify.closer = ']'
6969
stringify.stringifier = JSON.stringify
7070
```

index.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@ function Stringify(options) {
2727

2828
// Array Deliminator and Stringifier defaults
2929
var opener = options && options.opener ? options.opener : '[\n'
30-
var seperator = options && options.seperator ? options.seperator : '\n,\n'
30+
var separator = options && options.separator ? options.separator : '\n,\n'
3131
var closer = options && options.closer ? options.closer : '\n]\n'
3232
var stringifier = options && options.stringifier ? options.stringifier : stringify
3333

3434
// Array Deliminators and Stringifier
3535
this.opener = new Buffer(opener, 'utf8')
36-
this.seperator = new Buffer(seperator, 'utf8')
36+
this.separator = new Buffer(separator, 'utf8')
3737
this.closer = new Buffer(closer, 'utf8')
3838
this.stringifier = stringifier
3939
}
@@ -47,7 +47,7 @@ Stringify.prototype.space = 0
4747

4848
Stringify.prototype._transform = function (doc, enc, cb) {
4949
if (this.started) {
50-
this.push(this.seperator)
50+
this.push(this.separator)
5151
} else {
5252
this.push(this.opener)
5353
this.started = true

test/test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,12 +178,12 @@ describe('Streamify()', function () {
178178
stream.end(obj)
179179
})
180180

181-
it('should allow custom seperators', function (done) {
181+
it('should allow custom separators', function (done) {
182182
var stream = new PassThrough({
183183
objectMode: true
184184
})
185185

186-
var stringify = Stringify({seperator: ' , '})
186+
var stringify = Stringify({separator: ' , '})
187187

188188
stream
189189
.pipe(stringify)

0 commit comments

Comments
 (0)