jaredhanson/locomotive — pull request #114 by redking (2013-11-28 09:46:59+00:00)
Title: Allows filters to pass additional arguments to next()

Hey,

The before filter example in the Locomotive documentation shows data attached as a pseudo-private attribute on `this` that is later used in the rendering callback.

I was wondering if there was a reason why the before filter cannot simply pass data via the second argument on the `next` callback? It seems as if it would make the code a little neater, and prevent accidental overwriting of existing `this` attributes (a potential problem when multiple developers with different Node/express abilities are working on the same codebase).

I've included a pull request, in case this is simple to resolve.