Fixed issue where we could get null rating keys on Plex

This commit is contained in:
tidusjar 2017-03-04 14:01:39 +00:00
commit 9637fe92f4

View file

@ -264,7 +264,7 @@ namespace Ombi.Services.Jobs
return media; return media;
}); });
if (item == null) if (item == null && !string.IsNullOrEmpty(m.ItemId))
{ {
// Doesn't exist, insert it // Doesn't exist, insert it
PlexContent.Insert(new PlexContent PlexContent.Insert(new PlexContent
@ -305,7 +305,7 @@ namespace Ombi.Services.Jobs
return media; return media;
}); });
if (item == null) if (item == null && !string.IsNullOrEmpty(t.ItemId))
{ {
PlexContent.Insert(new PlexContent PlexContent.Insert(new PlexContent
{ {