Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Ticket #8571 (closed enhancement: fixed)

Opened 1 year ago

Last modified 1 year ago

[PATCH] Refactoring Date::Calculations; adding Date.yesterday and Date.tomorrow constructors

Reported by: gbuesing Assigned to: core
Priority: normal Milestone: 1.x
Component: ActiveSupport Version: edge
Severity: normal Keywords:
Cc:

Description

This patch refactors the Date::Calculations module so that instance methods aren't in the ClassMethods module, and adds two class methods: Date.yesterday and Date.tomorrow, which are simple shorthand constructors for Date.today.yesterday and Date.today.tomorrow.

Tests included for new constructors.

Attachments

refactoring_and_adding_yesterday_and_tomorrow_constructors.diff (12.6 kB) - added by gbuesing on 06/04/07 18:12:33.

Change History

06/04/07 18:12:33 changed by gbuesing

  • attachment refactoring_and_adding_yesterday_and_tomorrow_constructors.diff added.

06/04/07 18:14:46 changed by bitsweat

  • status changed from new to closed.
  • resolution set to fixed.

(In [6934]) Date.yesterday and .tomorrow. Closes #8571.