xmaker: fix reset today

This commit is contained in:
c9s 2021-07-06 11:07:30 +08:00
parent 1d316ed89c
commit 5e2b8af4dc

View File

@ -108,7 +108,7 @@ func (s *ProfitStats) AddTrade(trade types.Trade) {
}
func (s *ProfitStats) IsOver24Hours() bool {
return time.Now().Sub(time.Unix(s.TodaySince, 0)) >= 24*time.Hour
return time.Since(time.Unix(s.TodaySince, 0)) > 24*time.Hour
}
func (s *ProfitStats) ResetToday() {