diff --git a/app/controllers/collections_controller.rb b/app/controllers/collections_controller.rb index 86816a138..8be474ebb 100644 --- a/app/controllers/collections_controller.rb +++ b/app/controllers/collections_controller.rb @@ -8,7 +8,7 @@ class CollectionsController < ApplicationController def index @models = filtered_models @filters @collections = policy_scope(Collection) - @collections = @collections.tree_both(Collection.find_param(@filters[:collection]).id || nil, @models.pluck(:collection_id).uniq) unless @filters.empty? + @collections = @collections.tree_both(Collection.find_param(@filters[:collection]).id || nil, @models.pluck(:collection_id).uniq) unless @filters[:collection].nil? @tags, @unrelated_tag_count = generate_tag_list(@models, @filter_tags) @tags, @kv_tags = split_key_value_tags(@tags)