diff options
Diffstat (limited to 'lib/date/format.rb')
-rw-r--r-- | lib/date/format.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/date/format.rb b/lib/date/format.rb index 39b46d0472..f0b73ac4fd 100644 --- a/lib/date/format.rb +++ b/lib/date/format.rb @@ -98,10 +98,8 @@ class Date t = '@' + t if set instance_variable_set(t, *args) - else - if instance_variables.include?(t) - instance_variable_get(t) - end + elsif instance_variable_defined?(t) + instance_variable_get(t) end end |