From 0e53f3330d3245d2f8760f2833aeecb80ebadb62 Mon Sep 17 00:00:00 2001 From: westh Date: Thu, 17 Feb 2022 22:21:00 +0100 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=90=9B=20handling=20of=20non-ascii?= =?UTF-8?q?=20search=20terms?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index c8c8dcc..10d4f17 100644 --- a/main.py +++ b/main.py @@ -101,6 +101,7 @@ def main(wf): return search_term = query[1] if len(query) == 1 else ' '.join(query[1:]) + search_term = search_term.decode('utf-8') cards_response = get_cards(search_term, user_token) is_denied_due_to_auth = cards_response.status_code == 401 if (is_denied_due_to_auth): @@ -113,7 +114,7 @@ def main(wf): is_no_card_found = len(cards) == 0 if (is_no_card_found): wf.add_item( - title='No cards found for "' + query + '"', + title='No cards found for "' + search_term + '"', valid=False ) wf.send_feedback()