mirror of https://github.com/statping/statping
fix: add totalList variable
parent
9c07ec46c3
commit
47aa812787
|
@ -276,6 +276,7 @@ func (s Service) OnlineDaysPercent(days int) float32 {
|
||||||
func (s *Service) OnlineSince(ago time.Time) float32 {
|
func (s *Service) OnlineSince(ago time.Time) float32 {
|
||||||
failsList := s.FailuresSince(ago).Count()
|
failsList := s.FailuresSince(ago).Count()
|
||||||
hitsList := s.HitsSince(ago).Count()
|
hitsList := s.HitsSince(ago).Count()
|
||||||
|
totalList := failsList+hitsList
|
||||||
|
|
||||||
if failsList == 0 {
|
if failsList == 0 {
|
||||||
s.Online24Hours = 100.00
|
s.Online24Hours = 100.00
|
||||||
|
|
Loading…
Reference in New Issue