mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-08 15:05:46 +01:00
add loggedIn state to template parsing
This commit is contained in:
@@ -321,6 +321,8 @@ middleware.processRender = function(req, res, next) {
|
||||
options = {};
|
||||
}
|
||||
|
||||
options.loggedIn = req.user ? parseInt(req.user.uid, 10) !== 0 : false;
|
||||
|
||||
if ('function' !== typeof fn) {
|
||||
fn = defaultFn;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user