mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-27 17:16:14 +01:00
filter:config.get
This commit is contained in:
@@ -86,11 +86,13 @@ apiController.getConfig = function(req, res, next) {
|
||||
config.categoryTopicSort = settings.categoryTopicSort || config.categoryTopicSort;
|
||||
config.topicSearchEnabled = settings.topicSearchEnabled || false;
|
||||
|
||||
if (res.locals.isAPI) {
|
||||
res.status(200).json(config);
|
||||
} else {
|
||||
next(err, config);
|
||||
}
|
||||
plugins.fireHook('filter:config.get', config, function(err, config) {
|
||||
if (res.locals.isAPI) {
|
||||
res.status(200).json(config);
|
||||
} else {
|
||||
next(err, config);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user