await res.json in ssfr inside catch block

This commit is contained in:
Georges-Antoine Assi
2025-07-13 20:40:16 -04:00
parent 39c7651a55
commit 0a5b2e5fa2

View File

@@ -111,6 +111,7 @@ class ScreenScraperService:
status_code=status.HTTP_401_UNAUTHORIZED,
detail="Invalid ScreenScraper credentials",
)
return await res.json()
except (aiohttp.ClientResponseError, aiohttp.ServerTimeoutError) as err:
if (
isinstance(err, aiohttp.ClientResponseError)
@@ -124,8 +125,6 @@ class ScreenScraperService:
log.error("Error decoding JSON response from ScreenScraper: %s", exc)
return {}
return await res.json()
async def get_game_info(
self,
*,