Bug 60372: Fix use of res.local function

Express 2.5 defines res.locals as a function on the prototype taking an
object. res.local can be used to set and retrieve request-local variables. See
parsoid-deploy/node_modules/express/lib/response.js line 250.

We were instead following the somewhat misleading express documentation which
suggests directly setting res.locals.foo. This would actually set properties
on the res.locals function object on the prototype. This in turn lead to it
being worker-global rather than per-request. With concurrent requests and an
async config fetch (to give another request the chance to be accepted) this
would result in redirects to the later request's wiki prefix.

Verified to fix the issue by running these two in parallel:

ab -c10 -n10000 http://localhost:8000/enwiki/Foo
ab -v9 'http://localhost:8000/skwiki/Hrabovka_(okres_Trenčín)'

Without the patch, the skwiki request would often redirect to /enwiki/.

Change-Id: Ib364f69d9d79b38d623d2400d83566b9ff8a423e
Merge "Bug 60372: Fix use of res.local function"