Class: ReeDatetime::Sunday
- Inherits:
-
Object
- Object
- ReeDatetime::Sunday
- Includes:
- Ree::FnDSL
- Defined in:
- lib/ree_lib/packages/ree_datetime/package/ree_datetime/functions/sunday.rb
Instance Method Summary collapse
Instance Method Details
#call(date_time = nil) ⇒ Object
15 16 17 18 19 20 21 22 23 24 |
# File 'lib/ree_lib/packages/ree_datetime/package/ree_datetime/functions/sunday.rb', line 15 def call(date_time = nil) date_time = date_time || now change( end_of_week(date_time, :monday), hour: date_time.hour, min: date_time.min, sec: date_time.sec ) end |