mirror of
https://github.com/meisnate12/Plex-Meta-Manager
synced 2024-11-10 06:54:21 +00:00
unpack issue
This commit is contained in:
parent
6fa97a21e3
commit
f3357aadba
2 changed files with 5 additions and 5 deletions
|
@ -2003,7 +2003,7 @@ class CollectionBuilder:
|
|||
rating_keys.remove(int(item.ratingKey))
|
||||
if "item_assets" in self.item_details or overlay is not None:
|
||||
try:
|
||||
self.library.find_assets(item, name=overlay)
|
||||
self.library.find_assets(item, overlay=overlay)
|
||||
except Failed as e:
|
||||
logger.error(e)
|
||||
self.library.edit_tags("label", item, add_tags=add_tags, remove_tags=remove_tags, sync_tags=sync_tags)
|
||||
|
|
|
@ -645,7 +645,7 @@ class Plex(Library):
|
|||
logger.info(f"{obj.title[:25]:<25} | {attr.capitalize()} | {display}")
|
||||
return len(display) > 0
|
||||
|
||||
def find_assets(self, item, name=None, upload=True):
|
||||
def find_assets(self, item, name=None, upload=True, overlay=None):
|
||||
if isinstance(item, Movie):
|
||||
name = os.path.basename(os.path.dirname(str(item.locations[0])))
|
||||
elif isinstance(item, Show):
|
||||
|
@ -707,7 +707,7 @@ class Plex(Library):
|
|||
|
||||
if poster or background:
|
||||
if upload:
|
||||
self.upload_images(item, poster=poster, background=background, overlay=name)
|
||||
self.upload_images(item, poster=poster, background=background, overlay=overlay)
|
||||
else:
|
||||
return poster, background
|
||||
if isinstance(item, Show):
|
||||
|
@ -745,12 +745,12 @@ class Plex(Library):
|
|||
self.upload_images(episode, poster=episode_poster)
|
||||
if self.show_missing_season_assets and found_season and missing_assets:
|
||||
util.print_multiline(f"Missing Season Posters for {item.title}{missing_assets}", info=True)
|
||||
if isinstance(item, (Movie, Show)) and not poster and name:
|
||||
if isinstance(item, (Movie, Show)) and not poster and overlay:
|
||||
self.upload_images(item, overlay=name)
|
||||
if self.create_asset_folders and self.asset_folders and not found_folder:
|
||||
os.makedirs(os.path.join(self.asset_directory[0], name), exist_ok=True)
|
||||
logger.info(f"Asset Directory Created: {os.path.join(self.asset_directory[0], name)}")
|
||||
elif isinstance(item, (Movie, Show)) and not name and self.asset_folders and not found_folder:
|
||||
elif isinstance(item, (Movie, Show)) and not overlay and self.asset_folders and not found_folder:
|
||||
logger.error(f"Asset Warning: No asset folder found called '{name}'")
|
||||
elif isinstance(item, (Movie, Show)) and not poster and not background and self.show_missing_assets:
|
||||
logger.error(f"Asset Warning: No poster or background found in an assets folder for '{name}'")
|
||||
|
|
Loading…
Reference in a new issue