1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Use available method rather than macro name checking

This commit is contained in:
Carlos Antonio da Silva 2014-07-31 23:10:47 -03:00
parent fe24ba881a
commit 20405e516b

View file

@ -77,7 +77,7 @@ module ActiveRecord
end
def ensure_mutable
if source_reflection.macro != :belongs_to
unless source_reflection.belongs_to?
raise HasManyThroughCantAssociateThroughHasOneOrManyReflection.new(owner, reflection)
end
end