Skip to content

Commit

Permalink
client/core: throttle with Ticker instead of Timer
Browse files Browse the repository at this point in the history
  • Loading branch information
BeastMode123456 authored and chappjc committed Aug 2, 2022
1 parent 7d939a2 commit 3a476f1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions client/core/core.go
Original file line number Diff line number Diff line change
Expand Up @@ -7743,10 +7743,9 @@ func (c *Core) fetchFiatExchangeRates() {
c.wg.Add(1)
go func() {
defer c.wg.Done()
tick := time.NewTimer(fiatRateRequestInterval)
tick := time.NewTicker(fiatRateRequestInterval)
defer tick.Stop()
for {

c.refreshFiatRates(ctx)

select {
Expand Down

0 comments on commit 3a476f1

Please sign in to comment.