Skip to content

Commit

Permalink
Fixed a sugestion
Browse files Browse the repository at this point in the history
  • Loading branch information
mjarkk committed May 18, 2019
1 parent f0af933 commit 68c8f54
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions keybinding.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,7 @@ func (kb *keybinding) matchKeypress(key Key, ch rune, mod Modifier) bool {
// matchView returns if the keybinding matches the current view.
func (kb *keybinding) matchView(v *View) bool {
// if the user is typing in a field, ignore char keys
if v == nil {
return false
}
if v.Editable && kb.ch != 0 {
if v == nil || (v.Editable && kb.ch != 0) {
return false
}
return kb.viewName == v.name
Expand Down

0 comments on commit 68c8f54

Please sign in to comment.