Add error check in 'filter:middleware.renderHeader' hook callback

v1.18.x
jsdream 10 years ago
parent 29fcbf6750
commit 103055b262

@ -287,6 +287,10 @@ middleware.renderHeader = function(req, res, callback) {
templateValues.template[res.locals.template] = true;
plugins.fireHook('filter:middleware.renderHeader', {templateValues: templateValues, req: req, res: res}, function(err, data) {
if (err) {
return callback(err);
}
app.render('header', data.templateValues, callback);
});
});

Loading…
Cancel
Save