mirror of
https://github.com/meisnate12/Plex-Meta-Manager
synced 2024-11-10 06:54:21 +00:00
[8] fix episode rating update
This commit is contained in:
parent
a0655e16c1
commit
e392f007cd
3 changed files with 10 additions and 5 deletions
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
|||
1.17.1-develop7
|
||||
1.17.1-develop8
|
||||
|
|
|
@ -656,7 +656,7 @@ First, open the metadata file [this will create the file if it doesn't already e
|
|||
[type this into your terminal]
|
||||
|
||||
```
|
||||
nano "config\Movies.yml"
|
||||
nano "config/Movies.yml"
|
||||
```
|
||||
|
||||
</details>
|
||||
|
|
|
@ -345,6 +345,7 @@ class Operations:
|
|||
|
||||
for ep in item.episodes():
|
||||
ep.batchEdits()
|
||||
batch_display = ""
|
||||
item_title = self.library.get_item_sort_title(ep, atr="title")
|
||||
|
||||
def get_episode_rating(attribute):
|
||||
|
@ -365,7 +366,7 @@ class Operations:
|
|||
logger.info(f"{item_title[:25]:<25} | No Rating Found")
|
||||
elif str(ep.audienceRating) != str(new_rating):
|
||||
ep.editField("audienceRating", new_rating)
|
||||
logger.info(f"\n{item_title[:25]:<25} | Audience Rating | {new_rating}")
|
||||
batch_display += f"\n{item_title[:25]:<25} | Audience Rating | {new_rating}"
|
||||
except Failed:
|
||||
pass
|
||||
|
||||
|
@ -376,7 +377,7 @@ class Operations:
|
|||
logger.info(f"{item_title[:25]:<25} | No Rating Found")
|
||||
elif str(ep.rating) != str(new_rating):
|
||||
ep.editField("rating", new_rating)
|
||||
logger.info(f"{item_title[:25]:<25} | Critic Rating | {new_rating}")
|
||||
batch_display += f"\n{item_title[:25]:<25} | Critic Rating | {new_rating}"
|
||||
except Failed:
|
||||
pass
|
||||
|
||||
|
@ -387,10 +388,14 @@ class Operations:
|
|||
logger.info(f"{item_title[:25]:<25} | No Rating Found")
|
||||
elif str(ep.userRating) != str(new_rating):
|
||||
ep.editField("userRating", new_rating)
|
||||
logger.info(f"{item_title[:25]:<25} | User Rating | {new_rating}")
|
||||
batch_display += f"\n{item_title[:25]:<25} | User Rating | {new_rating}"
|
||||
except Failed:
|
||||
pass
|
||||
|
||||
item.saveEdits()
|
||||
if len(batch_display) > 0:
|
||||
logger.info(f"Batch Edits{batch_display}")
|
||||
|
||||
if self.library.Radarr and self.library.radarr_add_all_existing:
|
||||
try:
|
||||
self.library.Radarr.add_tmdb(radarr_adds)
|
||||
|
|
Loading…
Reference in a new issue