mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-07 22:45:46 +01:00
filter links and children
This commit is contained in:
@@ -491,6 +491,9 @@ app.cacheBuster = null;
|
||||
if (err) {
|
||||
return app.alertError(err.message);
|
||||
}
|
||||
categories = categories.filter(function(category) {
|
||||
return !category.link && !parseInt(category.parentCid, 10);
|
||||
});
|
||||
if (categories.length) {
|
||||
$(window).trigger('action:composer.topic.new', {
|
||||
cid: categories[0].cid
|
||||
|
||||
Reference in New Issue
Block a user