forked from svrjs/svrjs
Fix bug with mods executing in wrong order (bug was related with access control vulnerability fix; bug was not present in LTS versions)
This commit is contained in:
parent
80dbafe3ee
commit
84b7cac684
1 changed files with 2 additions and 2 deletions
4
svr.js
4
svr.js
|
@ -2642,7 +2642,7 @@ if (!cluster.isPrimary) {
|
||||||
});
|
});
|
||||||
|
|
||||||
var modFunction = ffinals;
|
var modFunction = ffinals;
|
||||||
proxyMods.reverse().forEach(function (proxyMod) {
|
proxyMods.slice().reverse().forEach(function (proxyMod) {
|
||||||
modFunction = proxyMod.proxyCallback(req, socket, head, configJSON, serverconsole, modFunction);
|
modFunction = proxyMod.proxyCallback(req, socket, head, configJSON, serverconsole, modFunction);
|
||||||
});
|
});
|
||||||
modFunction();
|
modFunction();
|
||||||
|
@ -3255,7 +3255,7 @@ if (!cluster.isPrimary) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
useMods.reverse().forEach(function (modO) {
|
useMods.slice().reverse().forEach(function (modO) {
|
||||||
modFunction = modO.callback(req, res, serverconsole, responseEnd, href, ext, uobject, search, "index.html", users, page404, head, foot, "", modFunction, configJSON, callServerError, getCustomHeaders, origHref, redirect, parsePostData);
|
modFunction = modO.callback(req, res, serverconsole, responseEnd, href, ext, uobject, search, "index.html", users, page404, head, foot, "", modFunction, configJSON, callServerError, getCustomHeaders, origHref, redirect, parsePostData);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Reference in a new issue