mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-23 23:58:31 -05:00
Oops, I made a spec fail by refactoring after I made the test pass and didn't check the tests
This commit is contained in:
parent
8e24a608b0
commit
52ee1928cc
1 changed files with 5 additions and 1 deletions
|
@ -53,7 +53,11 @@ class CategoryList
|
|||
@categories.delete_if { |c| c.featured_topics.blank? }
|
||||
else
|
||||
# Show all categories to people who have the ability to edit and delete categories
|
||||
@categories.insert(@categories.size, *Category.where('id not in (?)', @categories.map(&:id).compact).to_a)
|
||||
if @categories.size > 0
|
||||
@categories.insert(@categories.size, *Category.where('id not in (?)', @categories.map(&:id).compact).to_a)
|
||||
else
|
||||
@categories = Category.all.to_a
|
||||
end
|
||||
end
|
||||
|
||||
# Get forum topic user records if appropriate
|
||||
|
|
Loading…
Reference in a new issue