accept IMDB IDs for TV episodes too
This commit is contained in:
parent
bcfaa0e5fb
commit
0663b423bd
1 changed files with 4 additions and 4 deletions
|
@ -481,7 +481,7 @@ def cleanup_result(item, media_type) -> dict:
|
|||
del item[f"original_{title_key}"], item["original_language"]
|
||||
|
||||
if "tv-episodes" == media_type:
|
||||
item['series']['tmdb_id'] = item['show_id']
|
||||
item['series'] = { 'tmdb_id': item['show_id'] }
|
||||
del item['show_id']
|
||||
|
||||
if "books" == media_type:
|
||||
|
@ -561,8 +561,8 @@ def main() -> None:
|
|||
|
||||
elif "tv-episodes" == media_type:
|
||||
log = "log"
|
||||
while re.search("[0-9]+", item_id) is None:
|
||||
item_id = input("Enter IMDB ID: ")
|
||||
while re.search("(tt)?[0-9]+", item_id) is None:
|
||||
item_id = input("Enter TVDB or IMDB ID: ")
|
||||
|
||||
elif "tv-series" == media_type:
|
||||
log = ""
|
||||
|
@ -572,7 +572,7 @@ def main() -> None:
|
|||
while re.search("[0-9]+", item_id) is None:
|
||||
item_id = input("Enter TMDB ID: ")
|
||||
|
||||
add_item_to_log(re.search("[0-9]+", item_id)[0], media_type, log)
|
||||
add_item_to_log(re.search("(tt)?[0-9]+", item_id)[0], media_type, log)
|
||||
|
||||
except Exception:
|
||||
logger.exception("Exception occurred")
|
||||
|
|
Loading…
Reference in a new issue