mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-27 01:24:07 +01:00
Changed all Date objects to Datetimes and migrated everything appropriately. Tests & specs pass, but this still needs a thorough review.
This commit is contained in:
parent
c85c5fd957
commit
778427405a
11 changed files with 49 additions and 16 deletions
|
|
@ -169,7 +169,11 @@ class User < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def date
|
||||
time.to_date
|
||||
time.midnight
|
||||
end
|
||||
|
||||
def at_midnight(date)
|
||||
return TimeZone[prefs.time_zone].local(date.year, date.month, date.day, 0, 0, 0)
|
||||
end
|
||||
|
||||
def generate_token
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue