Skip to content
Myr

`app.helpers` -> `app.locals`

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

authored by Tj Holowaychuk · committed by Tj Holowaychuk · parent 0815921 · Browse files · 2 files+1 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+1 added−2 removed

  • tests:+1 added−1 removed
  • other:+0 added−1 removed

2 files+1 added−2 removed

modified:lib/http.js-1 removed
260 unmodified lines
261 * @return {Server} for chaining262 * @api public263 */264265app.helpers =265app.locals = function(obj){266 utils.merge(this._locals, obj);267 return this;268};
232 unmodified lines
modified:test/view.test.js+1 added-1 removed
320 unmodified lines
321 app.locals({322 lastName: 'holowaychuk'323 });324 325 app.helpers({ 325 app.locals({ 326 greetings: function(sess, lastName){327 return 'Hello ' + sess.name + ' ' + lastName; 328 }329 });
823 unmodified lines