diff --git a/core/failures.go b/core/failures.go index 38fcaefc..6cdd0762 100644 --- a/core/failures.go +++ b/core/failures.go @@ -129,7 +129,7 @@ func CountFailures() uint64 { func (s *Service) TotalFailuresOnDate(ago time.Time) (uint64, error) { var count uint64 date := ago.UTC().Format("2006-01-02 00:00:00") - dateend := ago.UTC().Format("2006-01-02 23:59:59") + dateend := ago.UTC().Format("2006-01-02") + " 23:59:59" rows := failuresDB().Where("service = ? AND created_at BETWEEN ? AND ?", s.Id, date, dateend).Not("method = 'checkin'") err := rows.Count(&count) return count, err.Error