mirror of
https://github.com/tendermint/tendermint.git
synced 2026-06-01 03:46:22 +00:00
Fix possibly incorrect usage of conversion
This commit is contained in:
@@ -36,8 +36,7 @@ func (t *defaultTicker) Chan() <-chan time.Time {
|
||||
|
||||
// Implements Ticker
|
||||
func (t *defaultTicker) Stop() {
|
||||
tt := time.Ticker(*t)
|
||||
tt.Stop()
|
||||
((*time.Ticker)(t)).Stop()
|
||||
}
|
||||
|
||||
//----------------------------------------
|
||||
|
||||
@@ -31,7 +31,7 @@ func TestRepeat(t *testing.T) {
|
||||
for i := 0; i < cnt; i++ {
|
||||
timeout := time.After(time.Second * 2)
|
||||
select {
|
||||
case _ = <-rt.Chan():
|
||||
case <-rt.Chan():
|
||||
case <-timeout:
|
||||
t.Fatal("expected RepeatTimer to fire")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user