From 8edfbc030cc48b092d58d2cbc1d5c1b9cc80e475 Mon Sep 17 00:00:00 2001 From: Timothy Quilling Date: Fri, 30 Jun 2023 01:33:19 -0400 Subject: [PATCH] chore: access context items safely --- find_posts.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/find_posts.py b/find_posts.py index fbf4c93..ac0b318 100644 --- a/find_posts.py +++ b/find_posts.py @@ -397,7 +397,8 @@ def get_all_known_context_urls(server, reply_toots, parsed_urls): parsed_url = parse_url(url, parsed_urls) context = get_toot_context(parsed_url[0], parsed_url[1], url) if context is not None: - known_context_urls.update(context) # type: ignore + for item in context: + known_context_urls.add(item) else: log(f"Error getting context for toot {url}")