refactor: extract shared settings_core and Flask route logic to domain/services

This commit is contained in:
Artem Akymenko
2026-07-19 15:52:35 +03:00
parent aec3462f1f
commit 64e8a8f4e6
11 changed files with 856 additions and 643 deletions
+2 -3
View File
@@ -344,7 +344,6 @@ class ExportService:
) -> None:
"""Upload to Audiobookshelf."""
if config is None:
# Load from job or global config
cfg = getattr(job, "_abs_config", None)
if cfg is None:
from abogen.utils import load_config
@@ -367,7 +366,7 @@ class ExportService:
if log_callback:
log_callback("Audiobookshelf upload skipped: not configured", "warning")
return
if not config.base_url or not config.api_token or not config.library_id:
if log_callback:
log_callback("Audiobookshelf upload skipped: configure base URL, API token, and library ID first", "warning")
@@ -376,7 +375,7 @@ class ExportService:
if log_callback:
log_callback("Audiobookshelf upload skipped: enter folder name or ID in settings", "warning")
return
if not audio_path.exists():
if log_callback:
log_callback("Audiobookshelf upload skipped: audio output not found", "warning")