fix disappearing collection tags (#1517)
This commit is contained in:
@@ -7,6 +7,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
|
||||
### Fixed
|
||||
- Fix playout builder crash with improperly configured pad filler preset
|
||||
- Properly validate filler preset mode pad to require `filler pad to nearest minute` value
|
||||
- Fix bug where previously-synchronized collection tags would disappear
|
||||
- This bug affected Jellyfin, Emby and Plex collections
|
||||
|
||||
## [0.8.3-beta] - 2023-11-22
|
||||
### Added
|
||||
|
||||
Generated
+4455
File diff suppressed because it is too large
Load Diff
+28
@@ -0,0 +1,28 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace ErsatzTV.Infrastructure.MySql.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class Reset_ExternalCollectionEtag : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.Sql("UPDATE PlexCollection SET Etag = NULL");
|
||||
migrationBuilder.Sql("UPDATE PlexMediaSource SET LastCollectionsScan = NULL");
|
||||
|
||||
migrationBuilder.Sql("UPDATE EmbyCollection SET Etag = NULL");
|
||||
migrationBuilder.Sql("UPDATE EmbyMediaSource SET LastCollectionsScan = NULL");
|
||||
|
||||
migrationBuilder.Sql("UPDATE JellyfinCollection SET Etag = NULL");
|
||||
migrationBuilder.Sql("UPDATE JellyfinMediaSource SET LastCollectionsScan = NULL");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -16,7 +16,7 @@ namespace ErsatzTV.Infrastructure.MySql.Migrations
|
||||
{
|
||||
#pragma warning disable 612, 618
|
||||
modelBuilder
|
||||
.HasAnnotation("ProductVersion", "7.0.13")
|
||||
.HasAnnotation("ProductVersion", "7.0.14")
|
||||
.HasAnnotation("Relational:MaxIdentifierLength", 64);
|
||||
|
||||
modelBuilder.Entity("ErsatzTV.Core.Domain.Actor", b =>
|
||||
|
||||
Generated
+4453
File diff suppressed because it is too large
Load Diff
+28
@@ -0,0 +1,28 @@
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace ErsatzTV.Infrastructure.Sqlite.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class Reset_ExternalCollectionEtag : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.Sql("UPDATE PlexCollection SET Etag = NULL");
|
||||
migrationBuilder.Sql("UPDATE PlexMediaSource SET LastCollectionsScan = NULL");
|
||||
|
||||
migrationBuilder.Sql("UPDATE EmbyCollection SET Etag = NULL");
|
||||
migrationBuilder.Sql("UPDATE EmbyMediaSource SET LastCollectionsScan = NULL");
|
||||
|
||||
migrationBuilder.Sql("UPDATE JellyfinCollection SET Etag = NULL");
|
||||
migrationBuilder.Sql("UPDATE JellyfinMediaSource SET LastCollectionsScan = NULL");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -15,7 +15,7 @@ namespace ErsatzTV.Infrastructure.Sqlite.Migrations
|
||||
protected override void BuildModel(ModelBuilder modelBuilder)
|
||||
{
|
||||
#pragma warning disable 612, 618
|
||||
modelBuilder.HasAnnotation("ProductVersion", "7.0.13");
|
||||
modelBuilder.HasAnnotation("ProductVersion", "7.0.14");
|
||||
|
||||
modelBuilder.Entity("ErsatzTV.Core.Domain.Actor", b =>
|
||||
{
|
||||
|
||||
@@ -733,6 +733,7 @@ public class EmbyTelevisionRepository : IEmbyTelevisionRepository
|
||||
// tags
|
||||
foreach (Tag tag in metadata.Tags
|
||||
.Filter(g => incomingMetadata.Tags.All(g2 => g2.Name != g.Name))
|
||||
.Filter(g => g.ExternalCollectionId is null)
|
||||
.ToList())
|
||||
{
|
||||
metadata.Tags.Remove(tag);
|
||||
|
||||
@@ -737,6 +737,7 @@ public class JellyfinTelevisionRepository : IJellyfinTelevisionRepository
|
||||
// tags
|
||||
foreach (Tag tag in metadata.Tags
|
||||
.Filter(g => incomingMetadata.Tags.All(g2 => g2.Name != g.Name))
|
||||
.Filter(g => g.ExternalCollectionId is null)
|
||||
.ToList())
|
||||
{
|
||||
metadata.Tags.Remove(tag);
|
||||
|
||||
@@ -318,6 +318,7 @@ public class PlexMovieLibraryScanner :
|
||||
|
||||
foreach (Tag tag in existingMetadata.Tags
|
||||
.Filter(g => fullMetadata.Tags.All(g2 => g2.Name != g.Name))
|
||||
.Filter(g => g.ExternalCollectionId is null)
|
||||
.ToList())
|
||||
{
|
||||
existingMetadata.Tags.Remove(tag);
|
||||
|
||||
@@ -413,6 +413,7 @@ public class PlexTelevisionLibraryScanner :
|
||||
|
||||
foreach (Tag tag in existingMetadata.Tags
|
||||
.Filter(g => fullMetadata.Tags.All(g2 => g2.Name != g.Name))
|
||||
.Filter(g => g.ExternalCollectionId is null)
|
||||
.ToList())
|
||||
{
|
||||
existingMetadata.Tags.Remove(tag);
|
||||
@@ -479,6 +480,7 @@ public class PlexTelevisionLibraryScanner :
|
||||
|
||||
foreach (Tag tag in existingMetadata.Tags
|
||||
.Filter(g => fullMetadata.Tags.All(g2 => g2.Name != g.Name))
|
||||
.Filter(g => g.ExternalCollectionId is null)
|
||||
.ToList())
|
||||
{
|
||||
existingMetadata.Tags.Remove(tag);
|
||||
@@ -540,6 +542,7 @@ public class PlexTelevisionLibraryScanner :
|
||||
|
||||
foreach (Tag tag in existingMetadata.Tags
|
||||
.Filter(g => fullMetadata.Tags.All(g2 => g2.Name != g.Name))
|
||||
.Filter(g => g.ExternalCollectionId is null)
|
||||
.ToList())
|
||||
{
|
||||
existingMetadata.Tags.Remove(tag);
|
||||
|
||||
Reference in New Issue
Block a user