Comparing version 1.4.1 to 1.4.2
@@ -7,7 +7,7 @@ "use strict"; | ||
this.position = 0; | ||
this.numBuffer = new Buffer(4); | ||
this.numBuffer = Buffer.alloc(4); | ||
} | ||
AbstractTokenizer.prototype.readToken = function (token, position) { | ||
if (position === void 0) { position = null; } | ||
var buffer = new Buffer(token.len); | ||
var buffer = Buffer.alloc(token.len); | ||
return this.readBuffer(buffer, 0, token.len, position).then(function (len) { | ||
@@ -21,3 +21,3 @@ if (len < token.len) | ||
if (position === void 0) { position = this.position; } | ||
var buffer = new Buffer(token.len); | ||
var buffer = Buffer.alloc(token.len); | ||
return this.peekBuffer(buffer, 0, token.len, position).then(function (len) { | ||
@@ -24,0 +24,0 @@ if (len < token.len) |
@@ -71,3 +71,3 @@ "use strict"; | ||
ReadStreamTokenizer.prototype.ignore = function (length) { | ||
var buf = new Buffer(length); | ||
var buf = Buffer.alloc(length); | ||
return this.readBuffer(buf); // Stream cannot skip data | ||
@@ -74,0 +74,0 @@ }; |
{ | ||
"name": "strtok3", | ||
"version": "1.4.1", | ||
"version": "1.4.2", | ||
"description": "A promise based streaming tokenizer", | ||
@@ -37,17 +37,16 @@ "author": { | ||
"@types/mocha": "^5.2.0", | ||
"@types/node": "^9.6.7", | ||
"@types/node": "^9.6.13", | ||
"chai": "^4.1.2", | ||
"mocha": "^5.1.1", | ||
"nyc": "^11.7.1", | ||
"ts-node": "^6.0.1", | ||
"tslint": "^5.9.1", | ||
"typescript": "^2.8.3", | ||
"hoek": "~> 4.2.1" | ||
"ts-node": "^6.0.3", | ||
"tslint": "^5.10.0", | ||
"typescript": "^2.8.3" | ||
}, | ||
"dependencies": { | ||
"bluebird": "^3.5.1", | ||
"coveralls": "^3.0.0", | ||
"coveralls": "^3.0.1", | ||
"fs-extra": "^5.0.0", | ||
"then-read-stream": "^1.1.0", | ||
"token-types": "^0.9.2" | ||
"then-read-stream": "^1.1.3", | ||
"token-types": "^0.9.4" | ||
}, | ||
@@ -54,0 +53,0 @@ "keywords": [ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
47343
10
Updatedcoveralls@^3.0.1
Updatedthen-read-stream@^1.1.3
Updatedtoken-types@^0.9.4