app/models/item_discover_presenter.rb
Use the return of the conditional for variable assignment and comparison. Open
Open
if %w[genre style].include?(field.to_s)
q << Item.sanitize_sql_for_assignment(["? = ANY (#{field.to_s.pluralize})", value])
else
q << Item.sanitize_sql_for_assignment(field => value)
end
- Exclude checks