Fix: Fixed an issue where the Sync Now button became unresponsive due to duplicate API calls.

This commit is contained in:
2025-12-02 09:55:57 +09:00
parent 15e7636a92
commit aa4517aaf5
2 changed files with 2 additions and 50 deletions
+2
View File
@@ -159,6 +159,7 @@ def _read_text_if_exists(path: str) -> tuple[str, bool]:
def _save_playlist_to_folder(filename: str, paths: Sequence[str], folder: str) -> str:
_ensure_test_dir(folder)
file_path = os.path.join(folder, filename)
logger.info(f"Saving playlist to: {file_path}")
new_content = save_paths(paths)
@@ -585,6 +586,7 @@ def sync_all_playlists(
server_config.load()
compiled_rules = _compile_regex_rules(server_config.path_rules)
_ensure_test_dir(test_folder)
logger.info(f"Syncing playlists to test folder: {test_folder}")
local_playlists = _load_local_playlists(local_dir)
remote_playlists = _fetch_remote_playlists()
playlist_names: set[str] = set(local_playlists.keys())