Class: RiotGamesApi::LOL::Model::Corecion::Time

Inherits:
Virtus::Attribute
  • Object
show all
Defined in:
lib/riot_games_api/lol/model/corecion/time.rb

Instance Method Summary collapse

Instance Method Details

#coerce(value) ⇒ Object



8
9
10
11
# File 'lib/riot_games_api/lol/model/corecion/time.rb', line 8

def coerce(value)
  unixtime_remove_millisecond = value / 1000
  ::Time.at(unixtime_remove_millisecond)
end