diff --git a/plugins/karma.py b/plugins/karma.py index bcd47c3..9e4786f 100644 --- a/plugins/karma.py +++ b/plugins/karma.py @@ -473,10 +473,13 @@ async def handle_command(room, message, bot, prefix, config): # Debug logging message_body = message.body if hasattr(message, 'body') else str(message) - logging.info(f"Karma plugin received message: '{message_body}' from {message.sender}") + logging.debug(f"Karma plugin received message: '{message_body}' from {message.sender}") # Get the full command (including what might be karma++ etc.) - full_cmd = match.command() if hasattr(match, 'command') else '' + try: + full_cmd = match.command() + except IndexError: + full_cmd = '' logging.debug(f"Full command: '{full_cmd}'")