diff --git a/ethermess.py b/ethermess.py index 1c5c37d..7f34d51 100644 --- a/ethermess.py +++ b/ethermess.py @@ -214,7 +214,17 @@ def handle_user_command(backend, line): try: if len(line) > 0 and line[0] == '/': - command, _, rest = line.partition(' ') + index = line.find(' ') + if index != -1: + command = line[:index] + + while index < len(line) and line[index] == ' ': + index += 1 + + rest = line[index:] + else: + command = line + rest = '' if command == '/': # Send quoted message