mirror of
https://github.com/gabehf/Koito.git
synced 2026-04-22 20:11:50 -07:00
maybe fixed for total listen activity
This commit is contained in:
parent
2925425750
commit
913c6c00e5
6 changed files with 95 additions and 47 deletions
|
|
@ -127,6 +127,12 @@ func DateRange(week, month, year int) (time.Time, time.Time, error) {
|
|||
return start, end, nil
|
||||
}
|
||||
|
||||
// Returns a time.Time that represents the first moment of the day of t.
|
||||
func BeginningOfDay(t time.Time) time.Time {
|
||||
year, month, day := t.Date()
|
||||
return time.Date(year, month, day, 0, 0, 0, 0, t.Location())
|
||||
}
|
||||
|
||||
// CopyFile copies a file from src to dst. If src and dst files exist, and are
|
||||
// the same, then return success. Otherise, attempt to create a hard link
|
||||
// between the two files. If that fail, copy the file contents from src to dst.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue