fix: #7118, invoking autoLocale middleware on logout

Also:
- firing client-side hook on header update
- updating bootbox locale on header update
v1.18.x
Julian Lam 6 years ago
parent 792dce1496
commit 900f0a0b78

@ -147,6 +147,8 @@ app.cacheBuster = null;
Chat.prepareDOM();
app.reskin(data.config.bootswatchSkin);
translator.switchTimeagoLanguage(callback);
bootbox.setLocale(config.userLang);
$(window).trigger('action:app.updateHeader');
});
});
};

@ -483,6 +483,7 @@ authenticationController.logout = function (req, res, next) {
function (next) {
plugins.fireHook('static:user.loggedOut', { req: req, res: res, uid: req.uid }, next);
},
async.apply(middleware.autoLocale, req, res),
function () {
// Force session check for all connected socket.io clients with the same session id
sockets.in('sess_' + req.sessionID).emit('checkSession', 0);

Loading…
Cancel
Save