diff options
Diffstat (limited to 'widgets/selector.go')
-rw-r--r-- | widgets/selector.go | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/widgets/selector.go b/widgets/selector.go index 71224c9b..8a1a1623 100644 --- a/widgets/selector.go +++ b/widgets/selector.go @@ -132,8 +132,7 @@ func (sel *Selector) Focus(focus bool) { } func (sel *Selector) Event(event tcell.Event) bool { - switch event := event.(type) { - case *tcell.EventKey: + if event, ok := event.(*tcell.EventKey); ok { switch event.Key() { case tcell.KeyCtrlH: fallthrough |