Fix null check in validation and handle exceptions in scraper

This commit is contained in:
mhdzumair
2025-02-01 17:13:11 +05:30
parent a7c1021d57
commit d84eafbce4
2 changed files with 4 additions and 2 deletions
+3 -1
View File
@@ -96,6 +96,8 @@ async def update_rpdb_posters(
if updated_poster:
meta.poster = updated_poster
await asyncio.gather(*(update_poster(meta) for meta in metas.metas))
await asyncio.gather(
*(update_poster(meta) for meta in metas.metas), return_exceptions=True
)
return metas
+1 -1
View File
@@ -245,7 +245,7 @@ def validate_parent_guide_nudity(metadata, user_data: schemas.UserData) -> bool:
Returns False if the content should be filtered out based on user preferences.
"""
# Strict policy for adult genres.
if "Adult" in metadata.genres:
if metadata.genres and "Adult" in metadata.genres:
return False
# Skip validation if filters are disabled