Sha256: 2606f2709d44b86fae303145c3580d7c6ad6a1319e18c46de9e155481b75565c
Contents?: true
Size: 382 Bytes
Versions: 8
Compression:
Stored size: 382 Bytes
Contents
module Timely module Time def on_date(year, month = nil, day = nil) if year.is_a?(Date) date = year year, month, day = date.year, date.month, date.day end raise ArgumentError, "Year, month, and day needed" unless [year, month, day].all? ::Time.local(year, month, day, hour, min, sec) end alias_method :on, :on_date end end
Version data entries
8 entries across 8 versions & 1 rubygems