Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

remove unnecessary is_a check

  • Loading branch information...
commit 0ee351b428e038394d495c20a868d40ad3032e83 1 parent d7e2310
@tenderlove tenderlove authored
Showing with 1 addition and 2 deletions.
  1. +1 −2  activerecord/lib/active_record/reflection.rb
View
3  activerecord/lib/active_record/reflection.rb
@@ -66,8 +66,7 @@ def reflect_on_all_associations(macro = nil)
# Invoice.reflect_on_association(:line_items).macro # returns :has_many
#
def reflect_on_association(association)
- reflection = reflections[association]
- reflection if reflection.is_a?(AssociationReflection)
+ reflections[association]
end
# Returns an array of AssociationReflection objects for all associations which have <tt>:autosave</tt> enabled.
Please sign in to comment.
Something went wrong with that request. Please try again.