Commit 9f586b81 authored by Toon Claes's avatar Toon Claes

Refactor long `if` condition to helper method for readability

parent a8c5f0be
......@@ -2,9 +2,16 @@ module EE
module SearchHelper
def search_filter_input_options(type)
options = super
options[:data][:'multiple-assignees'] = 'true' if (type == :issues) && @project.feature_available?(:multiple_issue_assignees)
options[:data][:'multiple-assignees'] = 'true' if search_multiple_assignees?(type)
options
end
private
def search_multiple_assignees?(type)
type == :issues &&
@project.feature_available?(:multiple_issue_assignees)
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