Skip to content
Myr

Add statusCode properties to two errors

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Douglas Christopher Wilson · committed by Douglas Christopher Wilson · parent 7d6c1e5 · Browse files · 2 files+2 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+2 added−2 removed

  • other:+2 added−2 removed

2 files+2 added−2 removed

modified:lib/router/layer.js+1 added-1 removed
modified:lib/response.js+1 added-1 removed
627 unmodified lines
628 } else if (fn) {629 fn();630 } else {631 var err = new Error('Not Acceptable');632 err.status = 406;632 err.status = err.statusCode = 406;633 err.types = normalizeTypes(keys).map(function(o){ return o.value });634 next(err);635 }636
417 unmodified lines