From 4e43895e4e46addb3e875a463ee3e6b6da23bda1 Mon Sep 17 00:00:00 2001 From: fundor333 Date: Mon, 29 Sep 2025 23:14:39 +0200 Subject: [PATCH] Fixes input handling for event URLs/IDs Moves the Meetup URL/ID extraction logic outside the conditional block that checks for an empty input. This ensures that the extraction logic is always executed, regardless of whether the event URL or ID was provided as a command-line argument or via user input. --- micro_meetup.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/micro_meetup.py b/micro_meetup.py index 62af8138..f9eca331 100644 --- a/micro_meetup.py +++ b/micro_meetup.py @@ -130,9 +130,9 @@ def main( return if text is None: text = input("Give me a Meetup event URL or ID: ") - match = re.search(r"meetup.com/.+?/events/(\d+)", text) - if match: - text = match.group(1) + match = re.search(r"meetup.com/.+?/events/(\d+)", text) + if match: + text = match.group(1) add_to_memory(text) data = fetch_event(text) convert_json_to_post(data)