Time#to_json monkeypatch: use Time#getutc instead of #utc, so that self is not modified

This commit is contained in:
Geoff Buesing 2009-03-18 13:36:22 -05:00 committed by Matt Aimonetti
parent d9417f3915
commit 1517622d53

View file

@ -10,7 +10,7 @@ class Time
# in your application.)
def to_json(options = nil)
u = self.utc
u = self.getutc
%("#{u.strftime("%Y/%m/%d %H:%M:%S +0000")}")
end