Fixing bugs in ActiveSupport::Date (#759) #2225

merged 0 commits into from Aug 4, 2011


None yet
4 participants

ghost commented Jul 23, 2011

There are two issues here:
#1) ActiveSupport::Date current method has a misleading conditional. is always returned because config.time_zone is set by default on a project.
#2) ActiveSupport::Date does not override the method. This means that the core ruby library's .today method is called which may be based off of a different time zone than what's set in config.time_zone.

Submitting a pull request.


guilleiguaran commented Jul 24, 2011

@Mochaleaf can you set a more descriptive message to the commit? :D


ghost commented Jul 24, 2011

Ah, I think most of the dialogue was covered inside of the linked issue: #759

scoz commented Jul 31, 2011

Rails newbie here, this really needs to go through.

Took me way too long to figure out why and Date.yesterday were returning the same day.


dmitriy-kiriyenko commented Jul 31, 2011



ghost commented Aug 4, 2011

Anything else I need to do here to get this pulled?


dmitriy-kiriyenko commented Aug 4, 2011

I believe you should remove merge commits. If you wish to update the pull request to the current code, you should rebase and then push origin pull_request_branch --force.

Perhaps it might be better to squash the 2 actual commits.

@ghost ghost merged commit 5b88219 into rails:3-1-stable Aug 4, 2011

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment