From 7d773df6a32ad5eb1181c1c900a278b6f7ad6488 Mon Sep 17 00:00:00 2001 From: Carl Worth Date: Tue, 5 Jan 2021 10:49:23 -0800 Subject: [PATCH] Fix error with missing search terems Some recent change made a command like "/hunt solved" result in an error. This commit fixes that. --- turbot/interaction.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/turbot/interaction.py b/turbot/interaction.py index 0f71b01..e6f7503 100644 --- a/turbot/interaction.py +++ b/turbot/interaction.py @@ -635,6 +635,7 @@ def hunt(turb, body, args): channel_id = body['channel_id'][0] response_url = body['response_url'][0] + terms = None if args: # The first word can be a puzzle status and all remaining word # (if any) are search terms. _But_, if the first word is not a @@ -649,7 +650,6 @@ def hunt(turb, body, args): status = 'unsolved' else: status = 'unsolved' - terms = None # Separate search terms on spaces (but allow for quotation marks # to capture spaces in a search term) -- 2.43.0