diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2012-04-18 11:33:50 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2012-04-18 11:33:50 -0700 |
commit | 476fa7aca2f64604ff164700d679511d369227b9 (patch) | |
tree | 1d73ff9d3e71ea3f07db9da755733b38e2000119 /activerecord/lib | |
parent | 89f99e81120e7ac608b71dad68bed2ace73b170e (diff) | |
parent | d92166cb26efa2f0bd8e2adad1b8024beefbfd81 (diff) | |
download | rails-476fa7aca2f64604ff164700d679511d369227b9.tar.gz rails-476fa7aca2f64604ff164700d679511d369227b9.tar.bz2 rails-476fa7aca2f64604ff164700d679511d369227b9.zip |
Merge pull request #5894 from norman/3-2-fix-nil-logger
Fix nil logger on 3.2
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/scoping/named.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/scoping/named.rb b/activerecord/lib/active_record/scoping/named.rb index 0edc3f1dcc..9c50baa647 100644 --- a/activerecord/lib/active_record/scoping/named.rb +++ b/activerecord/lib/active_record/scoping/named.rb @@ -191,7 +191,7 @@ module ActiveRecord protected def valid_scope_name?(name) - if respond_to?(name, true) + if logger && respond_to?(name, true) logger.warn "Creating scope :#{name}. " \ "Overwriting existing method #{self.name}.#{name}." end |