Skip to content

v5.0.1

Latest

Choose a tag to compare

@jkyberneees jkyberneees released this 31 May 09:07
eabbfce

Bug fixes and a request hot-path performance improvement. No API changes.

⚠️ Notable behavior change

  • prioRequestsProcessing now correctly defaults to true even when you pass a partial config (e.g. zero({ router }), zero({ errorHandler })). Previously the documented default only applied to the zero-argument call zero(), and any config object silently disabled it. On standard http/https servers this means requests are now dispatched via setImmediate as documented. Set prioRequestsProcessing: false explicitly to opt out. (#52)

Bug fixes

  • Cross-request req.params leak: route matches served from the LRU cache shared a single params object across all requests to the same method+path. A middleware mutating req.params could bleed state into later requests. req.params is now shallow-copied per request. (#52)

Performance

  • ~36% faster query-string parsing on the request hot path: the array-notation regex now runs only when []= is present, and the prototype-pollution segment check skips its per-parameter allocation for normal keys. Behavior is identical, including __proto__/prototype/constructor filtering. (#53)

Internal

  • Landing page modernized; added regression and query-parser tests (suite: 71 passing, query parser at 100% line coverage).
  • Removed the TRON donate address from the README Support section. (#54)

Full changelog: v5.0.0...v5.0.1