Fixes for PR #185

This commit is contained in:
Feross Aboukhadijeh 2017-02-02 17:23:46 -08:00
parent 76165007ba
commit 27ae148167

View File

@ -25,7 +25,7 @@ function parseHttpRequest (req, opts) {
if (!params.port) throw new Error('invalid port') if (!params.port) throw new Error('invalid port')
params.left = Number(params.left) params.left = Number(params.left)
if (isNaN(params.left)) params.left = Infinity if (Number.isNaN(params.left)) params.left = Infinity
params.compact = Number(params.compact) || 0 params.compact = Number(params.compact) || 0
params.numwant = Math.min( params.numwant = Math.min(