Skip to content

Commit

Permalink
Merge pull request #35 from rnagabhyrava/develop
Browse files Browse the repository at this point in the history
Added exceptions at poster and description updates
  • Loading branch information
rnagabhyrava authored Jul 22, 2022
2 parents bd855aa + 6d66196 commit 0d95a87
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions plex-playlist-sync/utils/plex.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,9 +163,20 @@ def update_or_create_plex_playlist(
plex_playlist = plex.playlist(playlist.name)

if playlist.description and userInputs.add_playlist_description:
plex_playlist.edit(summary=playlist.description)
try:
plex_playlist.edit(summary=playlist.description)
except:
logging.info(
"Failed to update description for playlist %s",
playlist.name,
)
if playlist.poster and userInputs.add_playlist_poster:
plex_playlist.uploadPoster(url=playlist.poster)
try:
plex_playlist.uploadPoster(url=playlist.poster)
except:
logging.info(
"Failed to update poster for playlist %s", playlist.name
)
logging.info(
"Updated playlist %s with summary and poster", playlist.name
)
Expand Down

0 comments on commit 0d95a87

Please sign in to comment.