mirror of
https://github.com/ditkrg/active_model_serializers.git
synced 2026-01-25 07:16:49 +00:00
merge upstream/master
This commit is contained in:
@@ -140,7 +140,7 @@ module ActiveModel
|
||||
self.class._associations.dup.each do |name, options|
|
||||
association = object.send(name)
|
||||
serializer_class = ActiveModel::Serializer.serializer_for(association)
|
||||
serializer = serializer_class.new(association)
|
||||
serializer = serializer_class.new(association) if serializer_class
|
||||
|
||||
if block_given?
|
||||
block.call(name, serializer, options[:options])
|
||||
|
||||
Reference in New Issue
Block a user