From 01d101b7adea7212c3a79e79c496f2b0b6c7f383 Mon Sep 17 00:00:00 2001 From: Quildra Date: Sat, 16 Nov 2024 09:56:01 +0000 Subject: [PATCH] - fix for cache key clash --- ui/workers/gather_encounter_locations.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ui/workers/gather_encounter_locations.py b/ui/workers/gather_encounter_locations.py index 2c2e7dc..c8a060d 100644 --- a/ui/workers/gather_encounter_locations.py +++ b/ui/workers/gather_encounter_locations.py @@ -153,7 +153,7 @@ class GatherEncountersWorker(QRunnable): if not page_data: return None - cache_key = f'locations_{url}_data' + cache_key = f'locations_{url}_data_{form}' if force_refresh: cache.purge(cache_key) @@ -325,11 +325,11 @@ class GatherEncountersWorker(QRunnable): form_text = form_text.strip('()') if "/" in form_text: - last_word = singularize(form_text.split()[-1]) + last_word = form_text.split()[-1] form_text = form_text.replace(last_word, "").strip() parts = form_text.split('/') for part in parts: - main_form = part.strip() + " " + last_word + main_form = part.strip() + " " + singularize(last_word) info = { "main_form": main_form, "sub_form": None