mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-06 22:15:48 +01:00
adding notifications.get hook
This commit is contained in:
@@ -75,6 +75,17 @@ notificationsController.get = function (req, res, next) {
|
|||||||
|
|
||||||
user.notifications.getNotifications(nids, req.uid, next);
|
user.notifications.getNotifications(nids, req.uid, next);
|
||||||
},
|
},
|
||||||
|
function (notifications, next) {
|
||||||
|
plugins.fireHook('filter:notifications.get', {
|
||||||
|
notifications: notifications,
|
||||||
|
}, function (err, data) {
|
||||||
|
if (err) {
|
||||||
|
return next(err);
|
||||||
|
}
|
||||||
|
|
||||||
|
next(null, data.notifications);
|
||||||
|
});
|
||||||
|
},
|
||||||
function (notifications) {
|
function (notifications) {
|
||||||
res.render('notifications', {
|
res.render('notifications', {
|
||||||
notifications: notifications,
|
notifications: notifications,
|
||||||
|
|||||||
Reference in New Issue
Block a user