fix updating music videos (#174)
This commit is contained in:
@@ -698,25 +698,28 @@ namespace ErsatzTV.Core.Metadata
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach (Actor actor in existing.Actors
|
if (existing is not MusicVideoMetadata)
|
||||||
.Filter(a => incoming.Actors.All(a2 => a2.Name != a.Name))
|
|
||||||
.ToList())
|
|
||||||
{
|
{
|
||||||
existing.Actors.Remove(actor);
|
foreach (Actor actor in existing.Actors
|
||||||
if (await _metadataRepository.RemoveActor(actor))
|
.Filter(a => incoming.Actors.All(a2 => a2.Name != a.Name))
|
||||||
|
.ToList())
|
||||||
{
|
{
|
||||||
updated = true;
|
existing.Actors.Remove(actor);
|
||||||
|
if (await _metadataRepository.RemoveActor(actor))
|
||||||
|
{
|
||||||
|
updated = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
foreach (Actor actor in incoming.Actors
|
foreach (Actor actor in incoming.Actors
|
||||||
.Filter(a => existing.Actors.All(a2 => a2.Name != a.Name))
|
.Filter(a => existing.Actors.All(a2 => a2.Name != a.Name))
|
||||||
.ToList())
|
.ToList())
|
||||||
{
|
|
||||||
existing.Actors.Add(actor);
|
|
||||||
if (await addActor(existing, actor))
|
|
||||||
{
|
{
|
||||||
updated = true;
|
existing.Actors.Add(actor);
|
||||||
|
if (await addActor(existing, actor))
|
||||||
|
{
|
||||||
|
updated = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -60,7 +60,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (Exception _)
|
catch (Exception)
|
||||||
{
|
{
|
||||||
// ignore
|
// ignore
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user