Hmm, time conversion fails, let's see what happened.
This commit is contained in:
parent
d900d78800
commit
1e7819e1aa
@ -118,8 +118,11 @@ func (h *RadioHandlers) LastSong(w http.ResponseWriter, r *http.Request) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
for _, song := range songs {
|
for _, song := range songs {
|
||||||
if tim, err := time.Parse("15:04-0700", song.Time); err == nil {
|
tim, err := time.Parse("15:04-0700", song.Time)
|
||||||
|
if err == nil {
|
||||||
song.Time = utils.ToClientTimezone(tim, r).Format("15:04")
|
song.Time = utils.ToClientTimezone(tim, r).Format("15:04")
|
||||||
|
} else {
|
||||||
|
h.logErr.Println("song time parse error:", err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user