Class: Oj::ActiveSupportHelper

Inherits:
Object
  • Object
show all
Defined in:
lib/oj/active_support_helper.rb

Overview

Exists only to handle the ActiveSupport::TimeWithZone.

Class Method Summary collapse

Class Method Details

.createTimeWithZone(utc, zone) ⇒ Object



9
10
11
# File 'lib/oj/active_support_helper.rb', line 9

def self.createTimeWithZone(utc, zone)
  ActiveSupport::TimeWithZone.new(utc - utc.gmt_offset, ActiveSupport::TimeZone[zone])
end