aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord
diff options
context:
space:
mode:
authorJoey Geiger <joey.geiger@irco.com>2015-01-29 09:26:44 -0700
committerJoey Geiger <joey.geiger@irco.com>2015-01-29 09:26:44 -0700
commitabce1aa289dca3afef2a2f48567bc18d6c623d61 (patch)
treede176d78d739465a5c9598036715b37bfb70c413 /activerecord
parent37f2defa9922e915ac021f303d1b0e3bcbafcd79 (diff)
downloadrails-abce1aa289dca3afef2a2f48567bc18d6c623d61.tar.gz
rails-abce1aa289dca3afef2a2f48567bc18d6c623d61.tar.bz2
rails-abce1aa289dca3afef2a2f48567bc18d6c623d61.zip
Fix ruby 2.2 comparable warnings
Check for correct value type in activerecord/fixtures.rb Check that zone can respond to expected values to make the comparison.
Diffstat (limited to 'activerecord')
-rw-r--r--activerecord/lib/active_record/fixtures.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/fixtures.rb b/activerecord/lib/active_record/fixtures.rb
index 1e6b5c5d69..d6eafb16b7 100644
--- a/activerecord/lib/active_record/fixtures.rb
+++ b/activerecord/lib/active_record/fixtures.rb
@@ -589,7 +589,7 @@ module ActiveRecord
# interpolate the fixture label
row.each do |key, value|
- row[key] = label if value == "$LABEL"
+ row[key] = label if value.is_a?(String) && value == "$LABEL"
end
# generate a primary key if necessary