aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--widgets/compose.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/widgets/compose.go b/widgets/compose.go
index d0a4629..a68bbe1 100644
--- a/widgets/compose.go
+++ b/widgets/compose.go
@@ -177,7 +177,10 @@ func (c *Composer) Bindings() string {
}
func (c *Composer) Event(event tcell.Event) bool {
- return c.focusable[c.focused].Event(event)
+ if c.editor != nil {
+ return c.focusable[c.focused].Event(event)
+ }
+ return false
}
func (c *Composer) Focus(focus bool) {