Commit 55320ff6 authored by Pavel Shutsin's avatar Pavel Shutsin

Add inheritance flexibility to issuable collections

parent 1cc87f50
...@@ -194,10 +194,9 @@ module IssuableCollections ...@@ -194,10 +194,9 @@ module IssuableCollections
end end
def collection_type def collection_type
@collection_type ||= case finder_type.name @collection_type ||= if finder_type <= IssuesFinder
when 'IssuesFinder'
'Issue' 'Issue'
when 'MergeRequestsFinder' elsif finder_type <= MergeRequestsFinder
'MergeRequest' 'MergeRequest'
end end
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment