Skip to content
Myr

Added res.helpers() as alias of res.locals()

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

to match app.locals() / app.helpers()

authored by Tj Holowaychuk · committed by Tj Holowaychuk · parent 3afbcd0 · Browse files · 1 file+2 added−1 removed
This commit

State

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

Diff stats

1 file+2 added−1 removed

  • other:+2 added−1 removed

1 file+2 added−1 removed

modified:lib/response.js+2 added-1 removed
409 unmodified lines
410 * @return {Object|Undefined}411 * @api public412 */413414res.locals = function(obj){414res.locals =415res.helpers = function(obj){416 if (obj) {417 for (var key in obj) {418 this.local(key, obj[key]);419 }
4 unmodified lines