From 356156543cb2f52fa93e8aeb932a1b06353b09f8 Mon Sep 17 00:00:00 2001 From: Carlos Antonio da Silva Date: Sun, 4 May 2014 11:00:37 -0300 Subject: Use the reader attribute rather than the instance var when possible --- .../lib/active_record/connection_adapters/abstract_adapter.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'activerecord/lib/active_record/connection_adapters') diff --git a/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb b/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb index 46827b0dcd..3b3b03ff6e 100644 --- a/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb +++ b/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb @@ -120,7 +120,7 @@ module ActiveRecord end def collector - if @prepared_statements + if prepared_statements SQLString.new else BindCollector.new @@ -388,7 +388,7 @@ module ActiveRecord end def without_prepared_statement?(binds) - !@prepared_statements || binds.empty? + !prepared_statements || binds.empty? end def column_for(table_name, column_name) # :nodoc: -- cgit v1.2.3