diff options
Diffstat (limited to 'activesupport/lib')
-rw-r--r-- | activesupport/lib/active_support/core_ext/time/marshal_with_utc_flag.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/activesupport/lib/active_support/core_ext/time/marshal_with_utc_flag.rb b/activesupport/lib/active_support/core_ext/time/marshal_with_utc_flag.rb index 656939947c..8d46d80251 100644 --- a/activesupport/lib/active_support/core_ext/time/marshal_with_utc_flag.rb +++ b/activesupport/lib/active_support/core_ext/time/marshal_with_utc_flag.rb @@ -9,11 +9,9 @@ if RUBY_VERSION < '1.9' time = _original_load(marshaled_time) time.instance_eval do if defined?(@marshal_with_utc_coercion) - remove_instance_variable("@marshal_with_utc_coercion") - utc - else - self + val = remove_instance_variable("@marshal_with_utc_coercion") end + val ? utc : self end end end |