Skip to content

Commit 978bbb4

Browse files
committed
Update loader_query.rb
stringify association key name (so that the associations can be also specified as symbols)
1 parent 1d5393c commit 978bbb4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/torque/postgresql/associations/preloader/loader_query.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ module Associations
66
module Preloader
77
module LoaderQuery
88
def foreign_column
9-
@foreign_column ||= scope.columns_hash[association_key_name]
9+
@foreign_column ||= scope.columns_hash[association_key_name.to_s]
1010
end
1111

1212
def load_records_for_keys(keys, &block)

0 commit comments

Comments
 (0)