Ignoring if title is none or type.

This commit is contained in:
Brage 2023-07-31 01:33:53 +02:00
parent 145be49e92
commit a174fe2aea
3 changed files with 7 additions and 0 deletions

View File

@ -21,6 +21,8 @@ class metadata():
type = 'movie' if result.get('airing_format', '').lower() == 'movie' else 'serie',
genres = result.get('genres', [])
)
if (meta.title is None) or (meta.type is None):
return DataResult("IGNORE", None, None)
return DataResult("SUCCESS", None, meta)

View File

@ -23,6 +23,8 @@ class metadata():
type = 'movie' if result.get('kind', '').lower() == 'movie' else 'serie',
genres = result.get('genres', [])
)
if (meta.title is None) or (meta.type is None):
return DataResult("IGNORE", None, None)
return DataResult("SUCCESS", None, meta)
except Exception as e:

View File

@ -24,6 +24,9 @@ class metadata():
type = 'movie' if anime.type.lower() == 'movie' else 'serie',
genres = anime.genres,
)
if (meta.title is None) or (meta.type is None):
return DataResult("IGNORE", None, None)
return DataResult("SUCCESS", None, meta)
except Exception as e:
return DataResult(statusType="ERROR", errorMessage=str(e))