update function defs

This commit is contained in:
Georges-Antoine Assi
2025-11-24 19:36:27 -05:00
parent 5b195065fe
commit bb351199f1
3 changed files with 22 additions and 15 deletions

View File

@@ -23,7 +23,7 @@ async def export_gamelist(
platform_ids: Annotated[
List[int], Query(description="List of platform IDs to export")
],
local_path: Annotated[
local_export: Annotated[
bool, Query(description="Use local paths instead of URLs")
] = False,
) -> Response:
@@ -35,13 +35,14 @@ async def export_gamelist(
)
try:
exporter = GamelistExporter()
exporter = GamelistExporter(local_export=local_export)
files_written = []
# Export each platform to its respective directory
for platform_id in platform_ids:
success = await exporter.export_platform_to_file(
platform_id, request if not local_path else None
platform_id,
request,
)
if success:
files_written.append(f"gamelist_{platform_id}.xml")