Skip to content

Commit

Permalink
Don't adjust a time.Duration twice
Browse files Browse the repository at this point in the history
  • Loading branch information
swi-jared committed Jul 9, 2024
1 parent 4aebb48 commit 5346f55
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/oboe/oboe.go
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ func (o *oboe) checkSettingsTimeout() {
log.Debug("checkSettingsTimeout: No settings")
return
}
e := s.timestamp.Add(time.Duration(s.ttl) * time.Second)
e := s.timestamp.Add(s.ttl)
log.Debugf("checkSettingsTimeout: ttl: %d, timestamp: %s, boundary: %s", s.ttl, s.timestamp, e)
if e.Before(time.Now()) {
log.Debugf("checkSettingsTimeout: ttl exceeded, expiring settings")
Expand Down

0 comments on commit 5346f55

Please sign in to comment.