1
0
mirror of https://github.com/taigrr/wtf synced 2025-01-18 04:03:14 -08:00

removed unused sleep code

This commit is contained in:
Bill Keenan 2018-06-06 11:05:47 -07:00 committed by GitHub
parent 56158d2e93
commit 1075096f2f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -62,28 +62,9 @@ func (widget *Widget) Refresh() {
return
}
if started == false {
// this code should run once
go func() {
for {
time.Sleep(time.Duration(widget.updateInterval) * time.Second)
}
}()
}
started = true
widget.UpdateRefreshedAt()
widget.View.Clear()
if !ok {
widget.View.SetText(
fmt.Sprint("Error!"),
)
return
}
display(widget)
}