Fix non-idempotence bug
This commit is contained in:
parent
47a2ab7649
commit
d0ab3f8d1e
@ -78,7 +78,7 @@ def add_anagrams(contents: str, anagrams_to_add: set[str], alphagram):
|
||||
existing.add(str(anagrams_template.get(i)))
|
||||
i += 1
|
||||
|
||||
if existing == anagrams_to_add:
|
||||
if existing.union(anagrams_to_add) == existing: # If there are no new anagrams present
|
||||
return contents
|
||||
|
||||
anagrams_to_add = anagrams_to_add.union(existing)
|
||||
|
Loading…
Reference in New Issue
Block a user