diff options
author | Sean Griffin <sean@seantheprogrammer.com> | 2015-10-22 07:07:27 -0600 |
---|---|---|
committer | Sean Griffin <sean@seantheprogrammer.com> | 2015-10-22 07:07:27 -0600 |
commit | b1e40cff80a58c6fdf95f2f9394badd70c36cb44 (patch) | |
tree | 9f35be1d3c16654bf7cfdfff0bdf623358486511 /activesupport/lib/active_support | |
parent | 3eda77f0eeeb479355b8845aa71cb0da1acd583d (diff) | |
parent | 0d2ce9d72396f449a15a3f914248cbc8cc8a4a4f (diff) | |
download | rails-b1e40cff80a58c6fdf95f2f9394badd70c36cb44.tar.gz rails-b1e40cff80a58c6fdf95f2f9394badd70c36cb44.tar.bz2 rails-b1e40cff80a58c6fdf95f2f9394badd70c36cb44.zip |
Merge pull request #19327 from rousisk/master
Change Integer#year to return a Fixnum instead of a Float to improve consistency
Diffstat (limited to 'activesupport/lib/active_support')
-rw-r--r-- | activesupport/lib/active_support/core_ext/integer/time.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/core_ext/integer/time.rb b/activesupport/lib/active_support/core_ext/integer/time.rb index f0b7382ef3..87185b024f 100644 --- a/activesupport/lib/active_support/core_ext/integer/time.rb +++ b/activesupport/lib/active_support/core_ext/integer/time.rb @@ -23,7 +23,7 @@ class Integer alias :month :months def years - ActiveSupport::Duration.new(self * 365.25.days, [[:years, self]]) + ActiveSupport::Duration.new(self * 365.25.days.to_i, [[:years, self]]) end alias :year :years end |