summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/tabs.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/tabs.py b/src/tabs.py
index 796c2f26..fff73467 100644
--- a/src/tabs.py
+++ b/src/tabs.py
@@ -282,11 +282,12 @@ class ChatTab(Tab):
def on_enter(self):
txt = self.input.key_enter()
- clean_text = xhtml.clean_text(txt)
- if not self.execute_command(clean_text):
- if txt.startswith('//'):
- txt = txt[1:]
- self.command_say(txt)
+ if txt:
+ clean_text = xhtml.clean_text(txt)
+ if not self.execute_command(clean_text):
+ if txt.startswith('//'):
+ txt = txt[1:]
+ self.command_say(txt)
self.cancel_paused_delay()
def send_chat_state(self, state):