From 5952861948a0918b1955202c1ea19589634537dc Mon Sep 17 00:00:00 2001 From: Matthew Draper Date: Thu, 4 Feb 2016 09:14:05 +1030 Subject: Extract a Relation#arel_attribute --- activerecord/lib/active_record/core.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'activerecord/lib/active_record/core.rb') diff --git a/activerecord/lib/active_record/core.rb b/activerecord/lib/active_record/core.rb index aa8f22ce42..24fd0aaecf 100644 --- a/activerecord/lib/active_record/core.rb +++ b/activerecord/lib/active_record/core.rb @@ -256,7 +256,7 @@ module ActiveRecord end end - def arel_attribute(name, table) # :nodoc: + def arel_attribute(name, table = arel_table) # :nodoc: name = attribute_alias(name) if attribute_alias?(name) table[name] end -- cgit v1.2.3