mirror of https://github.com/calzoneman/sync.git
Fix merge error
This commit is contained in:
parent
47ef670f34
commit
04336c9712
|
@ -15,7 +15,7 @@ function merge(locals, res) {
|
||||||
siteAuthor: "Calvin 'calzoneman' 'cyzon' Montgomery",
|
siteAuthor: "Calvin 'calzoneman' 'cyzon' Montgomery",
|
||||||
loginDomain: Config.get("https.enabled") ? Config.get("https.full-address")
|
loginDomain: Config.get("https.enabled") ? Config.get("https.full-address")
|
||||||
: Config.get("http.full-address"),
|
: Config.get("http.full-address"),
|
||||||
csrfToken: res.req.csrfToken(),
|
csrfToken: typeof res.req.csrfToken === 'function' ? res.req.csrfToken() : '',
|
||||||
baseUrl: getBaseUrl(res)
|
baseUrl: getBaseUrl(res)
|
||||||
};
|
};
|
||||||
if (typeof locals !== "object") {
|
if (typeof locals !== "object") {
|
||||||
|
|
|
@ -144,7 +144,6 @@ module.exports = {
|
||||||
init: function (app, webConfig, ioConfig, clusterClient, channelIndex, session) {
|
init: function (app, webConfig, ioConfig, clusterClient, channelIndex, session) {
|
||||||
app.use((req, res, next) => {
|
app.use((req, res, next) => {
|
||||||
counters.add("http:request", 1);
|
counters.add("http:request", 1);
|
||||||
req._ip = ipForRequest(req);
|
|
||||||
next();
|
next();
|
||||||
});
|
});
|
||||||
require('./middleware/x-forwarded-for')(app, webConfig);
|
require('./middleware/x-forwarded-for')(app, webConfig);
|
||||||
|
|
Loading…
Reference in New Issue