Skip to content

Instantly share code, notes, and snippets.

@jugyo
Created Feb 3, 2018
Embed
What would you like to do?
Time#milliseconds
class Time
unless Time.method_defined?(:milliseconds)
def milliseconds
(to_f * 1000).to_i
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment