We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5058edd commit dd43997Copy full SHA for dd43997
app/services/forest_liana/belongs_to_updater.rb
@@ -17,7 +17,7 @@ def perform
17
if @data.nil?
18
new_value = nil
19
else
20
- association_klass = SchemaUtils.polymorphic_models(@association).select { |a| a.name.downcase == @data[:type] }.first
+ association_klass = SchemaUtils.polymorphic_models(@association).select { |a| a.name == @data[:type] }.first
21
new_value = association_klass.find(@data[:id]) if @data && @data[:id]
22
end
23
0 commit comments