Skip to content

Commit

Permalink
deps: bytes@2.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
dougwilson committed May 22, 2015
1 parent 676973c commit 3d84811
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
6 changes: 6 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
unreleased
==========

* deps: bytes@2.1.0
- Slight optimizations

2.0.1 / 2015-05-10
==================

Expand Down
4 changes: 1 addition & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,7 @@ function getRawBody(stream, options, callback) {
: 'utf-8'

// convert the limit to an integer
var limit = typeof opts.limit === 'number' ? opts.limit
: typeof opts.limit === 'string' ? bytes(opts.limit)
: null
var limit = bytes.parse(opts.limit)

// convert the expected length to an integer
var length = opts.length != null && !isNaN(opts.length)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"license": "MIT",
"repository": "stream-utils/raw-body",
"dependencies": {
"bytes": "2.0.1",
"bytes": "2.1.0",
"iconv-lite": "0.4.8"
},
"devDependencies": {
Expand Down

0 comments on commit 3d84811

Please sign in to comment.