mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-15 10:16:12 +01:00
closes #2777
This commit is contained in:
@@ -123,25 +123,20 @@ define('forum/unread', ['forum/recent', 'topicSelect', 'forum/infinitescroll'],
|
||||
}
|
||||
|
||||
function createCategoryLinks(categories) {
|
||||
categories = categories.filter(function(category) {
|
||||
return !category.disabled;
|
||||
});
|
||||
|
||||
for(var i=0; i<categories.length; ++i) {
|
||||
for (var i=0; i<categories.length; ++i) {
|
||||
createCategoryLink(categories[i]);
|
||||
}
|
||||
}
|
||||
|
||||
function createCategoryLink(category) {
|
||||
|
||||
var link = $('<a role="menuitem" href="#"></a>');
|
||||
|
||||
if (category.icon) {
|
||||
link.append('<i class="fa fa-fw ' + category.icon + '"></i> ' + category.name);
|
||||
} else {
|
||||
link.append(category.name);
|
||||
}
|
||||
|
||||
|
||||
$('<li role="presentation" class="category" data-cid="' + category.cid + '"></li>')
|
||||
.append(link)
|
||||
.appendTo($('.markread .dropdown-menu'));
|
||||
|
||||
Reference in New Issue
Block a user