diff options
author | Geoff Buesing <gbuesing@gmail.com> | 2009-04-05 10:08:54 -0500 |
---|---|---|
committer | Geoff Buesing <gbuesing@gmail.com> | 2009-04-05 10:08:54 -0500 |
commit | c00f2d25de640b8de1c8583474085f3836ee1768 (patch) | |
tree | 22f03541c018920e31a4865d827ea40f9763b200 /activesupport/lib/active_support | |
parent | 70de8e64e30092b2b1b77869e459b4868f5b9577 (diff) | |
download | rails-c00f2d25de640b8de1c8583474085f3836ee1768.tar.gz rails-c00f2d25de640b8de1c8583474085f3836ee1768.tar.bz2 rails-c00f2d25de640b8de1c8583474085f3836ee1768.zip |
TimeWithZone.name returns 'Time', to further thwart type checking
Diffstat (limited to 'activesupport/lib/active_support')
-rw-r--r-- | activesupport/lib/active_support/time_with_zone.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/activesupport/lib/active_support/time_with_zone.rb b/activesupport/lib/active_support/time_with_zone.rb index 518ca7742f..2574f4e88e 100644 --- a/activesupport/lib/active_support/time_with_zone.rb +++ b/activesupport/lib/active_support/time_with_zone.rb @@ -31,6 +31,11 @@ module ActiveSupport # t.is_a?(Time) # => true # t.is_a?(ActiveSupport::TimeWithZone) # => true class TimeWithZone + + def self.name + 'Time' # Report class name as 'Time' to thwart type checking + end + include Comparable attr_reader :time_zone |