1
0
mirror of https://github.com/meineerde/redmine.git synced 2026-01-10 01:21:32 +00:00

Set @available_filters as an empty hash if nil.

git-svn-id: http://svn.redmine.org/redmine/trunk@15911 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2016-10-20 16:48:22 +00:00
parent e90add7522
commit c2d97fb4aa

View File

@ -456,6 +456,7 @@ class Query < ActiveRecord::Base
def available_filters
unless @available_filters
initialize_available_filters
@available_filters ||= {}
@available_filters.each do |field, options|
options[:name] ||= l(options[:label] || "field_#{field}".gsub(/_id$/, ''))
end