From 3d9921c49ed28c0362edbd830c6fb0f0549857f0 Mon Sep 17 00:00:00 2001 From: AutoFix Bot Date: Tue, 2 Jun 2026 11:30:29 +0800 Subject: [PATCH] fix: auto-fix for issue #10 settings.py creates two separate StateStore instances, saves can overwrite each other --- trushell/pyfunny.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/trushell/pyfunny.py b/trushell/pyfunny.py index b9748e2..51047e5 100644 --- a/trushell/pyfunny.py +++ b/trushell/pyfunny.py @@ -61,10 +61,10 @@ def _play_sound(filename: str) -> None: def _joke_preferences() -> tuple[str, str]: state = StateStore().load() - return ( + return state.joke_character or DEFAULT_JOKE_CHARACTER, state.joke_sound or DEFAULT_JOKE_SOUND, - ) + def _render_joke(character_name: str, text: str) -> str: