From ba7ec73f6a5c98c008e8e48eb06e9b9a17a91991 Mon Sep 17 00:00:00 2001 From: Jon Leighton Date: Fri, 23 Dec 2011 21:37:52 +0000 Subject: Deal with global config better between AR::Base and AR::Model --- activerecord/lib/active_record/locking/optimistic.rb | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'activerecord/lib/active_record/locking/optimistic.rb') diff --git a/activerecord/lib/active_record/locking/optimistic.rb b/activerecord/lib/active_record/locking/optimistic.rb index 27267c9d38..b80d01db81 100644 --- a/activerecord/lib/active_record/locking/optimistic.rb +++ b/activerecord/lib/active_record/locking/optimistic.rb @@ -48,10 +48,7 @@ module ActiveRecord module Optimistic extend ActiveSupport::Concern - included do - cattr_accessor :lock_optimistically, :instance_writer => false - self.lock_optimistically = true - end + Configuration.define :lock_optimistically, true def locking_enabled? #:nodoc: self.class.locking_enabled? -- cgit v1.2.3