fix: Fix tests

This commit is contained in:
2026-02-20 22:25:24 +03:00
parent d102524146
commit 43d4560fbb
6 changed files with 97 additions and 102 deletions
+6 -7
View File
@@ -78,7 +78,6 @@ func (d Provider) parseResponse(res *req.Response) ([]prayer.Times, error) {
}
var times []prayer.Times
const format = "15:04"
today := time.Now().UTC().Truncate(time.Hour * 24)
for _, pt := range response.ResultObject.PrayerTimes {
then := prayer.Date(pt.Date).Time()
@@ -88,12 +87,12 @@ func (d Provider) parseResponse(res *req.Response) ([]prayer.Times, error) {
times = append(times, prayer.Times{
Date: pt.Date.Format(time.DateOnly),
Fajr: pt.Fajr.Format(format),
Sunrise: pt.Sunrise.Format(format),
Dhuhr: pt.Dhuhr.Format(format),
Asr: pt.Asr.Format(format),
Maghrib: pt.Maghrib.Format(format),
Isha: pt.Isha.Format(format),
Fajr: pt.Fajr.Format(time.TimeOnly),
Sunrise: pt.Sunrise.Format(time.TimeOnly),
Dhuhr: pt.Dhuhr.Format(time.TimeOnly),
Asr: pt.Asr.Format(time.TimeOnly),
Maghrib: pt.Maghrib.Format(time.TimeOnly),
Isha: pt.Isha.Format(time.TimeOnly),
})
}
return times, nil