Skip to content

Commit

Permalink
Add missing line
Browse files Browse the repository at this point in the history
  • Loading branch information
shleikes committed Oct 9, 2024
1 parent 34db25c commit ca3ee23
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions protocol/performance/cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,9 +108,12 @@ func (cache *Cache) SetEntry(ctx context.Context, cacheSet *pairingtypes.RelayCa
if cache == nil {
return NotInitializedError
}

if cache.client == nil {
go cache.reconnectLoop()
return NotConnectedError.Wrapf("No client connected to address: %s", cache.address)
}

_, err := cache.client.SetRelay(ctx, cacheSet)
cache.reconnectIfNeeded(err)
return err
Expand Down

0 comments on commit ca3ee23

Please sign in to comment.