< Summary - Jellyfin

Line coverage
99%
Covered lines: 1725
Uncovered lines: 4
Coverable lines: 1729
Total lines: 1828
Line coverage: 99.7%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Coverage history

Coverage history 0 25 50 75 100 5/16/2026 - 12:15:55 AM Line coverage: 99.7% (1719/1723) Total lines: 18225/22/2026 - 12:15:17 AM Line coverage: 99.7% (1722/1726) Total lines: 18258/11/2026 - 12:17:00 AM Line coverage: 99.7% (1725/1729) Total lines: 1828

Coverage delta

Coverage delta 1 -1

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
File 1: Up(...)100%11100%
File 1: Down(...)100%210%
File 2: BuildTargetModel(...)100%11100%

File(s)

/srv/git/jellyfin/src/Jellyfin.Database/Jellyfin.Database.Providers.Sqlite/Migrations/20260118182305_AddIndicesToImageInfo.cs

#LineLine coverage
 1using Microsoft.EntityFrameworkCore.Migrations;
 2
 3#nullable disable
 4
 5namespace Jellyfin.Database.Providers.Sqlite.Migrations
 6{
 7    /// <inheritdoc />
 8    public partial class AddIndicesToImageInfo : Migration
 9    {
 10        /// <inheritdoc />
 11        protected override void Up(MigrationBuilder migrationBuilder)
 12        {
 2713            migrationBuilder.CreateIndex(
 2714                name: "IX_BaseItemImageInfos_ItemId_ImageType",
 2715                table: "BaseItemImageInfos",
 2716                columns: new[] { "ItemId", "ImageType" });
 2717        }
 18
 19        /// <inheritdoc />
 20        protected override void Down(MigrationBuilder migrationBuilder)
 21        {
 022            migrationBuilder.DropIndex(
 023                name: "IX_BaseItemImageInfos_ItemId_ImageType",
 024                table: "BaseItemImageInfos");
 025        }
 26    }
 27}

/srv/git/jellyfin/src/Jellyfin.Database/Jellyfin.Database.Providers.Sqlite/Migrations/20260118182305_AddIndicesToImageInfo.Designer.cs

#LineLine coverage
 1// <auto-generated />
 2using System;
 3using Jellyfin.Database.Implementations;
 4using Microsoft.EntityFrameworkCore;
 5using Microsoft.EntityFrameworkCore.Infrastructure;
 6using Microsoft.EntityFrameworkCore.Migrations;
 7using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
 8
 9#nullable disable
 10
 11namespace Jellyfin.Database.Providers.Sqlite.Migrations
 12{
 13    [DbContext(typeof(JellyfinDbContext))]
 14    [Migration("20260118182305_AddIndicesToImageInfo")]
 15    partial class AddIndicesToImageInfo
 16    {
 17        /// <inheritdoc />
 18        protected override void BuildTargetModel(ModelBuilder modelBuilder)
 19        {
 20#pragma warning disable 612, 618
 2721            modelBuilder.HasAnnotation("ProductVersion", "10.0.2");
 22
 2723            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AccessSchedule", b =>
 2724                {
 2725                    b.Property<int>("Id")
 2726                        .ValueGeneratedOnAdd()
 2727                        .HasColumnType("INTEGER");
 2728
 2729                    b.Property<int>("DayOfWeek")
 2730                        .HasColumnType("INTEGER");
 2731
 2732                    b.Property<double>("EndHour")
 2733                        .HasColumnType("REAL");
 2734
 2735                    b.Property<double>("StartHour")
 2736                        .HasColumnType("REAL");
 2737
 2738                    b.Property<Guid>("UserId")
 2739                        .HasColumnType("TEXT");
 2740
 2741                    b.HasKey("Id");
 2742
 2743                    b.HasIndex("UserId");
 2744
 2745                    b.ToTable("AccessSchedules");
 2746
 2747                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 2748                });
 49
 2750            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ActivityLog", b =>
 2751                {
 2752                    b.Property<int>("Id")
 2753                        .ValueGeneratedOnAdd()
 2754                        .HasColumnType("INTEGER");
 2755
 2756                    b.Property<DateTime>("DateCreated")
 2757                        .HasColumnType("TEXT");
 2758
 2759                    b.Property<string>("ItemId")
 2760                        .HasMaxLength(256)
 2761                        .HasColumnType("TEXT");
 2762
 2763                    b.Property<int>("LogSeverity")
 2764                        .HasColumnType("INTEGER");
 2765
 2766                    b.Property<string>("Name")
 2767                        .IsRequired()
 2768                        .HasMaxLength(512)
 2769                        .HasColumnType("TEXT");
 2770
 2771                    b.Property<string>("Overview")
 2772                        .HasMaxLength(512)
 2773                        .HasColumnType("TEXT");
 2774
 2775                    b.Property<uint>("RowVersion")
 2776                        .IsConcurrencyToken()
 2777                        .HasColumnType("INTEGER");
 2778
 2779                    b.Property<string>("ShortOverview")
 2780                        .HasMaxLength(512)
 2781                        .HasColumnType("TEXT");
 2782
 2783                    b.Property<string>("Type")
 2784                        .IsRequired()
 2785                        .HasMaxLength(256)
 2786                        .HasColumnType("TEXT");
 2787
 2788                    b.Property<Guid>("UserId")
 2789                        .HasColumnType("TEXT");
 2790
 2791                    b.HasKey("Id");
 2792
 2793                    b.HasIndex("DateCreated");
 2794
 2795                    b.ToTable("ActivityLogs");
 2796
 2797                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 2798                });
 99
 27100            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AncestorId", b =>
 27101                {
 27102                    b.Property<Guid>("ItemId")
 27103                        .HasColumnType("TEXT");
 27104
 27105                    b.Property<Guid>("ParentItemId")
 27106                        .HasColumnType("TEXT");
 27107
 27108                    b.HasKey("ItemId", "ParentItemId");
 27109
 27110                    b.HasIndex("ParentItemId");
 27111
 27112                    b.ToTable("AncestorIds");
 27113
 27114                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27115                });
 116
 27117            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AttachmentStreamInfo", b =>
 27118                {
 27119                    b.Property<Guid>("ItemId")
 27120                        .HasColumnType("TEXT");
 27121
 27122                    b.Property<int>("Index")
 27123                        .HasColumnType("INTEGER");
 27124
 27125                    b.Property<string>("Codec")
 27126                        .HasColumnType("TEXT");
 27127
 27128                    b.Property<string>("CodecTag")
 27129                        .HasColumnType("TEXT");
 27130
 27131                    b.Property<string>("Comment")
 27132                        .HasColumnType("TEXT");
 27133
 27134                    b.Property<string>("Filename")
 27135                        .HasColumnType("TEXT");
 27136
 27137                    b.Property<string>("MimeType")
 27138                        .HasColumnType("TEXT");
 27139
 27140                    b.HasKey("ItemId", "Index");
 27141
 27142                    b.ToTable("AttachmentStreamInfos");
 27143
 27144                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27145                });
 146
 27147            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemEntity", b =>
 27148                {
 27149                    b.Property<Guid>("Id")
 27150                        .ValueGeneratedOnAdd()
 27151                        .HasColumnType("TEXT");
 27152
 27153                    b.Property<string>("Album")
 27154                        .HasColumnType("TEXT");
 27155
 27156                    b.Property<string>("AlbumArtists")
 27157                        .HasColumnType("TEXT");
 27158
 27159                    b.Property<string>("Artists")
 27160                        .HasColumnType("TEXT");
 27161
 27162                    b.Property<int?>("Audio")
 27163                        .HasColumnType("INTEGER");
 27164
 27165                    b.Property<Guid?>("ChannelId")
 27166                        .HasColumnType("TEXT");
 27167
 27168                    b.Property<string>("CleanName")
 27169                        .HasColumnType("TEXT");
 27170
 27171                    b.Property<float?>("CommunityRating")
 27172                        .HasColumnType("REAL");
 27173
 27174                    b.Property<float?>("CriticRating")
 27175                        .HasColumnType("REAL");
 27176
 27177                    b.Property<string>("CustomRating")
 27178                        .HasColumnType("TEXT");
 27179
 27180                    b.Property<string>("Data")
 27181                        .HasColumnType("TEXT");
 27182
 27183                    b.Property<DateTime?>("DateCreated")
 27184                        .HasColumnType("TEXT");
 27185
 27186                    b.Property<DateTime?>("DateLastMediaAdded")
 27187                        .HasColumnType("TEXT");
 27188
 27189                    b.Property<DateTime?>("DateLastRefreshed")
 27190                        .HasColumnType("TEXT");
 27191
 27192                    b.Property<DateTime?>("DateLastSaved")
 27193                        .HasColumnType("TEXT");
 27194
 27195                    b.Property<DateTime?>("DateModified")
 27196                        .HasColumnType("TEXT");
 27197
 27198                    b.Property<DateTime?>("EndDate")
 27199                        .HasColumnType("TEXT");
 27200
 27201                    b.Property<string>("EpisodeTitle")
 27202                        .HasColumnType("TEXT");
 27203
 27204                    b.Property<string>("ExternalId")
 27205                        .HasColumnType("TEXT");
 27206
 27207                    b.Property<string>("ExternalSeriesId")
 27208                        .HasColumnType("TEXT");
 27209
 27210                    b.Property<string>("ExternalServiceId")
 27211                        .HasColumnType("TEXT");
 27212
 27213                    b.Property<int?>("ExtraType")
 27214                        .HasColumnType("INTEGER");
 27215
 27216                    b.Property<string>("ForcedSortName")
 27217                        .HasColumnType("TEXT");
 27218
 27219                    b.Property<string>("Genres")
 27220                        .HasColumnType("TEXT");
 27221
 27222                    b.Property<int?>("Height")
 27223                        .HasColumnType("INTEGER");
 27224
 27225                    b.Property<int?>("IndexNumber")
 27226                        .HasColumnType("INTEGER");
 27227
 27228                    b.Property<int?>("InheritedParentalRatingSubValue")
 27229                        .HasColumnType("INTEGER");
 27230
 27231                    b.Property<int?>("InheritedParentalRatingValue")
 27232                        .HasColumnType("INTEGER");
 27233
 27234                    b.Property<bool>("IsFolder")
 27235                        .HasColumnType("INTEGER");
 27236
 27237                    b.Property<bool>("IsInMixedFolder")
 27238                        .HasColumnType("INTEGER");
 27239
 27240                    b.Property<bool>("IsLocked")
 27241                        .HasColumnType("INTEGER");
 27242
 27243                    b.Property<bool>("IsMovie")
 27244                        .HasColumnType("INTEGER");
 27245
 27246                    b.Property<bool>("IsRepeat")
 27247                        .HasColumnType("INTEGER");
 27248
 27249                    b.Property<bool>("IsSeries")
 27250                        .HasColumnType("INTEGER");
 27251
 27252                    b.Property<bool>("IsVirtualItem")
 27253                        .HasColumnType("INTEGER");
 27254
 27255                    b.Property<float?>("LUFS")
 27256                        .HasColumnType("REAL");
 27257
 27258                    b.Property<string>("MediaType")
 27259                        .HasColumnType("TEXT");
 27260
 27261                    b.Property<string>("Name")
 27262                        .HasColumnType("TEXT");
 27263
 27264                    b.Property<float?>("NormalizationGain")
 27265                        .HasColumnType("REAL");
 27266
 27267                    b.Property<string>("OfficialRating")
 27268                        .HasColumnType("TEXT");
 27269
 27270                    b.Property<string>("OriginalLanguage")
 27271                        .HasColumnType("TEXT");
 27272
 27273                    b.Property<string>("OriginalTitle")
 27274                        .HasColumnType("TEXT");
 27275
 27276                    b.Property<string>("Overview")
 27277                        .HasColumnType("TEXT");
 27278
 27279                    b.Property<Guid?>("OwnerId")
 27280                        .HasColumnType("TEXT");
 27281
 27282                    b.Property<Guid?>("ParentId")
 27283                        .HasColumnType("TEXT");
 27284
 27285                    b.Property<int?>("ParentIndexNumber")
 27286                        .HasColumnType("INTEGER");
 27287
 27288                    b.Property<string>("Path")
 27289                        .HasColumnType("TEXT");
 27290
 27291                    b.Property<string>("PreferredMetadataCountryCode")
 27292                        .HasColumnType("TEXT");
 27293
 27294                    b.Property<string>("PreferredMetadataLanguage")
 27295                        .HasColumnType("TEXT");
 27296
 27297                    b.Property<DateTime?>("PremiereDate")
 27298                        .HasColumnType("TEXT");
 27299
 27300                    b.Property<string>("PresentationUniqueKey")
 27301                        .HasColumnType("TEXT");
 27302
 27303                    b.Property<string>("PrimaryVersionId")
 27304                        .HasColumnType("TEXT");
 27305
 27306                    b.Property<string>("ProductionLocations")
 27307                        .HasColumnType("TEXT");
 27308
 27309                    b.Property<int?>("ProductionYear")
 27310                        .HasColumnType("INTEGER");
 27311
 27312                    b.Property<long?>("RunTimeTicks")
 27313                        .HasColumnType("INTEGER");
 27314
 27315                    b.Property<Guid?>("SeasonId")
 27316                        .HasColumnType("TEXT");
 27317
 27318                    b.Property<string>("SeasonName")
 27319                        .HasColumnType("TEXT");
 27320
 27321                    b.Property<Guid?>("SeriesId")
 27322                        .HasColumnType("TEXT");
 27323
 27324                    b.Property<string>("SeriesName")
 27325                        .HasColumnType("TEXT");
 27326
 27327                    b.Property<string>("SeriesPresentationUniqueKey")
 27328                        .HasColumnType("TEXT");
 27329
 27330                    b.Property<string>("ShowId")
 27331                        .HasColumnType("TEXT");
 27332
 27333                    b.Property<long?>("Size")
 27334                        .HasColumnType("INTEGER");
 27335
 27336                    b.Property<string>("SortName")
 27337                        .HasColumnType("TEXT");
 27338
 27339                    b.Property<DateTime?>("StartDate")
 27340                        .HasColumnType("TEXT");
 27341
 27342                    b.Property<string>("Studios")
 27343                        .HasColumnType("TEXT");
 27344
 27345                    b.Property<string>("Tagline")
 27346                        .HasColumnType("TEXT");
 27347
 27348                    b.Property<string>("Tags")
 27349                        .HasColumnType("TEXT");
 27350
 27351                    b.Property<Guid?>("TopParentId")
 27352                        .HasColumnType("TEXT");
 27353
 27354                    b.Property<int?>("TotalBitrate")
 27355                        .HasColumnType("INTEGER");
 27356
 27357                    b.Property<string>("Type")
 27358                        .IsRequired()
 27359                        .HasColumnType("TEXT");
 27360
 27361                    b.Property<string>("UnratedType")
 27362                        .HasColumnType("TEXT");
 27363
 27364                    b.Property<int?>("Width")
 27365                        .HasColumnType("INTEGER");
 27366
 27367                    b.HasKey("Id");
 27368
 27369                    b.HasIndex("ExtraType");
 27370
 27371                    b.HasIndex("OwnerId");
 27372
 27373                    b.HasIndex("ParentId");
 27374
 27375                    b.HasIndex("Path");
 27376
 27377                    b.HasIndex("PresentationUniqueKey");
 27378
 27379                    b.HasIndex("ExtraType", "OwnerId");
 27380
 27381                    b.HasIndex("TopParentId", "Id");
 27382
 27383                    b.HasIndex("Type", "TopParentId", "Id");
 27384
 27385                    b.HasIndex("Type", "TopParentId", "PresentationUniqueKey");
 27386
 27387                    b.HasIndex("Type", "TopParentId", "StartDate");
 27388
 27389                    b.HasIndex("Id", "Type", "IsFolder", "IsVirtualItem");
 27390
 27391                    b.HasIndex("MediaType", "TopParentId", "IsVirtualItem", "PresentationUniqueKey");
 27392
 27393                    b.HasIndex("TopParentId", "IsFolder", "IsVirtualItem", "DateCreated");
 27394
 27395                    b.HasIndex("TopParentId", "MediaType", "IsVirtualItem", "DateCreated");
 27396
 27397                    b.HasIndex("TopParentId", "Type", "IsVirtualItem", "DateCreated");
 27398
 27399                    b.HasIndex("Type", "SeriesPresentationUniqueKey", "IsFolder", "IsVirtualItem");
 27400
 27401                    b.HasIndex("Type", "SeriesPresentationUniqueKey", "PresentationUniqueKey", "SortName");
 27402
 27403                    b.HasIndex("IsFolder", "TopParentId", "IsVirtualItem", "PresentationUniqueKey", "DateCreated");
 27404
 27405                    b.HasIndex("Type", "TopParentId", "IsVirtualItem", "PresentationUniqueKey", "DateCreated");
 27406
 27407                    b.ToTable("BaseItems");
 27408
 27409                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27410
 27411                    b.HasData(
 27412                        new
 27413                        {
 27414                            Id = new Guid("00000000-0000-0000-0000-000000000001"),
 27415                            IsFolder = false,
 27416                            IsInMixedFolder = false,
 27417                            IsLocked = false,
 27418                            IsMovie = false,
 27419                            IsRepeat = false,
 27420                            IsSeries = false,
 27421                            IsVirtualItem = false,
 27422                            Name = "This is a placeholder item for UserData that has been detached from its original ite
 27423                            Type = "PLACEHOLDER"
 27424                        });
 27425                });
 426
 27427            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemImageInfo", b =>
 27428                {
 27429                    b.Property<Guid>("Id")
 27430                        .ValueGeneratedOnAdd()
 27431                        .HasColumnType("TEXT");
 27432
 27433                    b.Property<byte[]>("Blurhash")
 27434                        .HasColumnType("BLOB");
 27435
 27436                    b.Property<DateTime?>("DateModified")
 27437                        .HasColumnType("TEXT");
 27438
 27439                    b.Property<int>("Height")
 27440                        .HasColumnType("INTEGER");
 27441
 27442                    b.Property<int>("ImageType")
 27443                        .HasColumnType("INTEGER");
 27444
 27445                    b.Property<Guid>("ItemId")
 27446                        .HasColumnType("TEXT");
 27447
 27448                    b.Property<string>("Path")
 27449                        .IsRequired()
 27450                        .HasColumnType("TEXT");
 27451
 27452                    b.Property<int>("Width")
 27453                        .HasColumnType("INTEGER");
 27454
 27455                    b.HasKey("Id");
 27456
 27457                    b.HasIndex("ItemId");
 27458
 27459                    b.HasIndex("ItemId", "ImageType");
 27460
 27461                    b.ToTable("BaseItemImageInfos");
 27462
 27463                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27464                });
 465
 27466            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemMetadataField", b =>
 27467                {
 27468                    b.Property<int>("Id")
 27469                        .HasColumnType("INTEGER");
 27470
 27471                    b.Property<Guid>("ItemId")
 27472                        .HasColumnType("TEXT");
 27473
 27474                    b.HasKey("Id", "ItemId");
 27475
 27476                    b.HasIndex("ItemId");
 27477
 27478                    b.ToTable("BaseItemMetadataFields");
 27479
 27480                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27481                });
 482
 27483            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemProvider", b =>
 27484                {
 27485                    b.Property<Guid>("ItemId")
 27486                        .HasColumnType("TEXT");
 27487
 27488                    b.Property<string>("ProviderId")
 27489                        .HasColumnType("TEXT");
 27490
 27491                    b.Property<string>("ProviderValue")
 27492                        .IsRequired()
 27493                        .HasColumnType("TEXT");
 27494
 27495                    b.HasKey("ItemId", "ProviderId");
 27496
 27497                    b.HasIndex("ProviderId", "ProviderValue", "ItemId");
 27498
 27499                    b.ToTable("BaseItemProviders");
 27500
 27501                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27502                });
 503
 27504            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemTrailerType", b =>
 27505                {
 27506                    b.Property<int>("Id")
 27507                        .HasColumnType("INTEGER");
 27508
 27509                    b.Property<Guid>("ItemId")
 27510                        .HasColumnType("TEXT");
 27511
 27512                    b.HasKey("Id", "ItemId");
 27513
 27514                    b.HasIndex("ItemId");
 27515
 27516                    b.ToTable("BaseItemTrailerTypes");
 27517
 27518                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27519                });
 520
 27521            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Chapter", b =>
 27522                {
 27523                    b.Property<Guid>("ItemId")
 27524                        .HasColumnType("TEXT");
 27525
 27526                    b.Property<int>("ChapterIndex")
 27527                        .HasColumnType("INTEGER");
 27528
 27529                    b.Property<DateTime?>("ImageDateModified")
 27530                        .HasColumnType("TEXT");
 27531
 27532                    b.Property<string>("ImagePath")
 27533                        .HasColumnType("TEXT");
 27534
 27535                    b.Property<string>("Name")
 27536                        .HasColumnType("TEXT");
 27537
 27538                    b.Property<long>("StartPositionTicks")
 27539                        .HasColumnType("INTEGER");
 27540
 27541                    b.HasKey("ItemId", "ChapterIndex");
 27542
 27543                    b.ToTable("Chapters");
 27544
 27545                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27546                });
 547
 27548            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.CustomItemDisplayPreferences", b =>
 27549                {
 27550                    b.Property<int>("Id")
 27551                        .ValueGeneratedOnAdd()
 27552                        .HasColumnType("INTEGER");
 27553
 27554                    b.Property<string>("Client")
 27555                        .IsRequired()
 27556                        .HasMaxLength(32)
 27557                        .HasColumnType("TEXT");
 27558
 27559                    b.Property<Guid>("ItemId")
 27560                        .HasColumnType("TEXT");
 27561
 27562                    b.Property<string>("Key")
 27563                        .IsRequired()
 27564                        .HasColumnType("TEXT");
 27565
 27566                    b.Property<Guid>("UserId")
 27567                        .HasColumnType("TEXT");
 27568
 27569                    b.Property<string>("Value")
 27570                        .HasColumnType("TEXT");
 27571
 27572                    b.HasKey("Id");
 27573
 27574                    b.HasIndex("UserId", "ItemId", "Client", "Key")
 27575                        .IsUnique();
 27576
 27577                    b.ToTable("CustomItemDisplayPreferences");
 27578
 27579                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27580                });
 581
 27582            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 27583                {
 27584                    b.Property<int>("Id")
 27585                        .ValueGeneratedOnAdd()
 27586                        .HasColumnType("INTEGER");
 27587
 27588                    b.Property<int>("ChromecastVersion")
 27589                        .HasColumnType("INTEGER");
 27590
 27591                    b.Property<string>("Client")
 27592                        .IsRequired()
 27593                        .HasMaxLength(32)
 27594                        .HasColumnType("TEXT");
 27595
 27596                    b.Property<string>("DashboardTheme")
 27597                        .HasMaxLength(32)
 27598                        .HasColumnType("TEXT");
 27599
 27600                    b.Property<bool>("EnableNextVideoInfoOverlay")
 27601                        .HasColumnType("INTEGER");
 27602
 27603                    b.Property<int?>("IndexBy")
 27604                        .HasColumnType("INTEGER");
 27605
 27606                    b.Property<Guid>("ItemId")
 27607                        .HasColumnType("TEXT");
 27608
 27609                    b.Property<int>("ScrollDirection")
 27610                        .HasColumnType("INTEGER");
 27611
 27612                    b.Property<bool>("ShowBackdrop")
 27613                        .HasColumnType("INTEGER");
 27614
 27615                    b.Property<bool>("ShowSidebar")
 27616                        .HasColumnType("INTEGER");
 27617
 27618                    b.Property<int>("SkipBackwardLength")
 27619                        .HasColumnType("INTEGER");
 27620
 27621                    b.Property<int>("SkipForwardLength")
 27622                        .HasColumnType("INTEGER");
 27623
 27624                    b.Property<string>("TvHome")
 27625                        .HasMaxLength(32)
 27626                        .HasColumnType("TEXT");
 27627
 27628                    b.Property<Guid>("UserId")
 27629                        .HasColumnType("TEXT");
 27630
 27631                    b.HasKey("Id");
 27632
 27633                    b.HasIndex("UserId", "ItemId", "Client")
 27634                        .IsUnique();
 27635
 27636                    b.ToTable("DisplayPreferences");
 27637
 27638                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27639                });
 640
 27641            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.HomeSection", b =>
 27642                {
 27643                    b.Property<int>("Id")
 27644                        .ValueGeneratedOnAdd()
 27645                        .HasColumnType("INTEGER");
 27646
 27647                    b.Property<int>("DisplayPreferencesId")
 27648                        .HasColumnType("INTEGER");
 27649
 27650                    b.Property<int>("Order")
 27651                        .HasColumnType("INTEGER");
 27652
 27653                    b.Property<int>("Type")
 27654                        .HasColumnType("INTEGER");
 27655
 27656                    b.HasKey("Id");
 27657
 27658                    b.HasIndex("DisplayPreferencesId");
 27659
 27660                    b.ToTable("HomeSection");
 27661
 27662                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27663                });
 664
 27665            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ImageInfo", b =>
 27666                {
 27667                    b.Property<int>("Id")
 27668                        .ValueGeneratedOnAdd()
 27669                        .HasColumnType("INTEGER");
 27670
 27671                    b.Property<DateTime>("LastModified")
 27672                        .HasColumnType("TEXT");
 27673
 27674                    b.Property<string>("Path")
 27675                        .IsRequired()
 27676                        .HasMaxLength(512)
 27677                        .HasColumnType("TEXT");
 27678
 27679                    b.Property<Guid?>("UserId")
 27680                        .HasColumnType("TEXT");
 27681
 27682                    b.HasKey("Id");
 27683
 27684                    b.HasIndex("UserId")
 27685                        .IsUnique();
 27686
 27687                    b.ToTable("ImageInfos");
 27688
 27689                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27690                });
 691
 27692            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemDisplayPreferences", b =>
 27693                {
 27694                    b.Property<int>("Id")
 27695                        .ValueGeneratedOnAdd()
 27696                        .HasColumnType("INTEGER");
 27697
 27698                    b.Property<string>("Client")
 27699                        .IsRequired()
 27700                        .HasMaxLength(32)
 27701                        .HasColumnType("TEXT");
 27702
 27703                    b.Property<int?>("IndexBy")
 27704                        .HasColumnType("INTEGER");
 27705
 27706                    b.Property<Guid>("ItemId")
 27707                        .HasColumnType("TEXT");
 27708
 27709                    b.Property<bool>("RememberIndexing")
 27710                        .HasColumnType("INTEGER");
 27711
 27712                    b.Property<bool>("RememberSorting")
 27713                        .HasColumnType("INTEGER");
 27714
 27715                    b.Property<string>("SortBy")
 27716                        .IsRequired()
 27717                        .HasMaxLength(64)
 27718                        .HasColumnType("TEXT");
 27719
 27720                    b.Property<int>("SortOrder")
 27721                        .HasColumnType("INTEGER");
 27722
 27723                    b.Property<Guid>("UserId")
 27724                        .HasColumnType("TEXT");
 27725
 27726                    b.Property<int>("ViewType")
 27727                        .HasColumnType("INTEGER");
 27728
 27729                    b.HasKey("Id");
 27730
 27731                    b.HasIndex("UserId");
 27732
 27733                    b.ToTable("ItemDisplayPreferences");
 27734
 27735                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27736                });
 737
 27738            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValue", b =>
 27739                {
 27740                    b.Property<Guid>("ItemValueId")
 27741                        .ValueGeneratedOnAdd()
 27742                        .HasColumnType("TEXT");
 27743
 27744                    b.Property<string>("CleanValue")
 27745                        .IsRequired()
 27746                        .HasColumnType("TEXT");
 27747
 27748                    b.Property<int>("Type")
 27749                        .HasColumnType("INTEGER");
 27750
 27751                    b.Property<string>("Value")
 27752                        .IsRequired()
 27753                        .HasColumnType("TEXT");
 27754
 27755                    b.HasKey("ItemValueId");
 27756
 27757                    b.HasIndex("Type", "CleanValue");
 27758
 27759                    b.HasIndex("Type", "Value")
 27760                        .IsUnique();
 27761
 27762                    b.ToTable("ItemValues");
 27763
 27764                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27765                });
 766
 27767            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValueMap", b =>
 27768                {
 27769                    b.Property<Guid>("ItemValueId")
 27770                        .HasColumnType("TEXT");
 27771
 27772                    b.Property<Guid>("ItemId")
 27773                        .HasColumnType("TEXT");
 27774
 27775                    b.HasKey("ItemValueId", "ItemId");
 27776
 27777                    b.HasIndex("ItemId");
 27778
 27779                    b.ToTable("ItemValuesMap");
 27780
 27781                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27782                });
 783
 27784            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.KeyframeData", b =>
 27785                {
 27786                    b.Property<Guid>("ItemId")
 27787                        .HasColumnType("TEXT");
 27788
 27789                    b.PrimitiveCollection<string>("KeyframeTicks")
 27790                        .HasColumnType("TEXT");
 27791
 27792                    b.Property<long>("TotalDuration")
 27793                        .HasColumnType("INTEGER");
 27794
 27795                    b.HasKey("ItemId");
 27796
 27797                    b.ToTable("KeyframeData");
 27798
 27799                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27800                });
 801
 27802            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.LinkedChildEntity", b =>
 27803                {
 27804                    b.Property<Guid>("ParentId")
 27805                        .HasColumnType("TEXT");
 27806
 27807                    b.Property<Guid>("ChildId")
 27808                        .HasColumnType("TEXT");
 27809
 27810                    b.Property<int>("ChildType")
 27811                        .HasColumnType("INTEGER");
 27812
 27813                    b.Property<int?>("SortOrder")
 27814                        .HasColumnType("INTEGER");
 27815
 27816                    b.HasKey("ParentId", "ChildId");
 27817
 27818                    b.HasIndex("ChildId");
 27819
 27820                    b.HasIndex("ParentId");
 27821
 27822                    b.HasIndex("ChildId", "ChildType");
 27823
 27824                    b.HasIndex("ParentId", "ChildType");
 27825
 27826                    b.HasIndex("ParentId", "SortOrder");
 27827
 27828                    b.ToTable("LinkedChildren", (string)null);
 27829
 27830                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27831                });
 832
 27833            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaSegment", b =>
 27834                {
 27835                    b.Property<Guid>("Id")
 27836                        .ValueGeneratedOnAdd()
 27837                        .HasColumnType("TEXT");
 27838
 27839                    b.Property<long>("EndTicks")
 27840                        .HasColumnType("INTEGER");
 27841
 27842                    b.Property<Guid>("ItemId")
 27843                        .HasColumnType("TEXT");
 27844
 27845                    b.Property<string>("SegmentProviderId")
 27846                        .IsRequired()
 27847                        .HasColumnType("TEXT");
 27848
 27849                    b.Property<long>("StartTicks")
 27850                        .HasColumnType("INTEGER");
 27851
 27852                    b.Property<int>("Type")
 27853                        .HasColumnType("INTEGER");
 27854
 27855                    b.HasKey("Id");
 27856
 27857                    b.ToTable("MediaSegments");
 27858
 27859                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 27860                });
 861
 27862            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaStreamInfo", b =>
 27863                {
 27864                    b.Property<Guid>("ItemId")
 27865                        .HasColumnType("TEXT");
 27866
 27867                    b.Property<int>("StreamIndex")
 27868                        .HasColumnType("INTEGER");
 27869
 27870                    b.Property<string>("AspectRatio")
 27871                        .HasColumnType("TEXT");
 27872
 27873                    b.Property<float?>("AverageFrameRate")
 27874                        .HasColumnType("REAL");
 27875
 27876                    b.Property<int?>("BitDepth")
 27877                        .HasColumnType("INTEGER");
 27878
 27879                    b.Property<int?>("BitRate")
 27880                        .HasColumnType("INTEGER");
 27881
 27882                    b.Property<int?>("BlPresentFlag")
 27883                        .HasColumnType("INTEGER");
 27884
 27885                    b.Property<string>("ChannelLayout")
 27886                        .HasColumnType("TEXT");
 27887
 27888                    b.Property<int?>("Channels")
 27889                        .HasColumnType("INTEGER");
 27890
 27891                    b.Property<string>("Codec")
 27892                        .HasColumnType("TEXT");
 27893
 27894                    b.Property<string>("CodecTag")
 27895                        .HasColumnType("TEXT");
 27896
 27897                    b.Property<string>("CodecTimeBase")
 27898                        .HasColumnType("TEXT");
 27899
 27900                    b.Property<string>("ColorPrimaries")
 27901                        .HasColumnType("TEXT");
 27902
 27903                    b.Property<string>("ColorSpace")
 27904                        .HasColumnType("TEXT");
 27905
 27906                    b.Property<string>("ColorTransfer")
 27907                        .HasColumnType("TEXT");
 27908
 27909                    b.Property<string>("Comment")
 27910                        .HasColumnType("TEXT");
 27911
 27912                    b.Property<int?>("DvBlSignalCompatibilityId")
 27913                        .HasColumnType("INTEGER");
 27914
 27915                    b.Property<int?>("DvLevel")
 27916                        .HasColumnType("INTEGER");
 27917
 27918                    b.Property<int?>("DvProfile")
 27919                        .HasColumnType("INTEGER");
 27920
 27921                    b.Property<int?>("DvVersionMajor")
 27922                        .HasColumnType("INTEGER");
 27923
 27924                    b.Property<int?>("DvVersionMinor")
 27925                        .HasColumnType("INTEGER");
 27926
 27927                    b.Property<int?>("ElPresentFlag")
 27928                        .HasColumnType("INTEGER");
 27929
 27930                    b.Property<bool?>("Hdr10PlusPresentFlag")
 27931                        .HasColumnType("INTEGER");
 27932
 27933                    b.Property<int?>("Height")
 27934                        .HasColumnType("INTEGER");
 27935
 27936                    b.Property<bool?>("IsAnamorphic")
 27937                        .HasColumnType("INTEGER");
 27938
 27939                    b.Property<bool?>("IsAvc")
 27940                        .HasColumnType("INTEGER");
 27941
 27942                    b.Property<bool>("IsDefault")
 27943                        .HasColumnType("INTEGER");
 27944
 27945                    b.Property<bool>("IsExternal")
 27946                        .HasColumnType("INTEGER");
 27947
 27948                    b.Property<bool>("IsForced")
 27949                        .HasColumnType("INTEGER");
 27950
 27951                    b.Property<bool?>("IsHearingImpaired")
 27952                        .HasColumnType("INTEGER");
 27953
 27954                    b.Property<bool?>("IsInterlaced")
 27955                        .HasColumnType("INTEGER");
 27956
 27957                    b.Property<bool>("IsOriginal")
 27958                        .HasColumnType("INTEGER");
 27959
 27960                    b.Property<string>("KeyFrames")
 27961                        .HasColumnType("TEXT");
 27962
 27963                    b.Property<string>("Language")
 27964                        .HasColumnType("TEXT");
 27965
 27966                    b.Property<float?>("Level")
 27967                        .HasColumnType("REAL");
 27968
 27969                    b.Property<string>("NalLengthSize")
 27970                        .HasColumnType("TEXT");
 27971
 27972                    b.Property<string>("Path")
 27973                        .HasColumnType("TEXT");
 27974
 27975                    b.Property<string>("PixelFormat")
 27976                        .HasColumnType("TEXT");
 27977
 27978                    b.Property<string>("Profile")
 27979                        .HasColumnType("TEXT");
 27980
 27981                    b.Property<float?>("RealFrameRate")
 27982                        .HasColumnType("REAL");
 27983
 27984                    b.Property<int?>("RefFrames")
 27985                        .HasColumnType("INTEGER");
 27986
 27987                    b.Property<int?>("Rotation")
 27988                        .HasColumnType("INTEGER");
 27989
 27990                    b.Property<int?>("RpuPresentFlag")
 27991                        .HasColumnType("INTEGER");
 27992
 27993                    b.Property<int?>("SampleRate")
 27994                        .HasColumnType("INTEGER");
 27995
 27996                    b.Property<int>("StreamType")
 27997                        .HasColumnType("INTEGER");
 27998
 27999                    b.Property<string>("TimeBase")
 271000                        .HasColumnType("TEXT");
 271001
 271002                    b.Property<string>("Title")
 271003                        .HasColumnType("TEXT");
 271004
 271005                    b.Property<int?>("Width")
 271006                        .HasColumnType("INTEGER");
 271007
 271008                    b.HasKey("ItemId", "StreamIndex");
 271009
 271010                    b.HasIndex("StreamIndex");
 271011
 271012                    b.HasIndex("StreamType");
 271013
 271014                    b.HasIndex("StreamIndex", "StreamType");
 271015
 271016                    b.HasIndex("StreamIndex", "StreamType", "Language");
 271017
 271018                    b.ToTable("MediaStreamInfos");
 271019
 271020                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271021                });
 1022
 271023            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.People", b =>
 271024                {
 271025                    b.Property<Guid>("Id")
 271026                        .ValueGeneratedOnAdd()
 271027                        .HasColumnType("TEXT");
 271028
 271029                    b.Property<string>("Name")
 271030                        .IsRequired()
 271031                        .HasColumnType("TEXT");
 271032
 271033                    b.Property<string>("PersonType")
 271034                        .HasColumnType("TEXT");
 271035
 271036                    b.HasKey("Id");
 271037
 271038                    b.HasIndex("Name");
 271039
 271040                    b.ToTable("Peoples");
 271041
 271042                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271043                });
 1044
 271045            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.PeopleBaseItemMap", b =>
 271046                {
 271047                    b.Property<Guid>("ItemId")
 271048                        .HasColumnType("TEXT");
 271049
 271050                    b.Property<Guid>("PeopleId")
 271051                        .HasColumnType("TEXT");
 271052
 271053                    b.Property<string>("Role")
 271054                        .HasColumnType("TEXT");
 271055
 271056                    b.Property<int?>("ListOrder")
 271057                        .HasColumnType("INTEGER");
 271058
 271059                    b.Property<int?>("SortOrder")
 271060                        .HasColumnType("INTEGER");
 271061
 271062                    b.HasKey("ItemId", "PeopleId", "Role");
 271063
 271064                    b.HasIndex("PeopleId");
 271065
 271066                    b.HasIndex("ItemId", "ListOrder");
 271067
 271068                    b.HasIndex("ItemId", "SortOrder");
 271069
 271070                    b.ToTable("PeopleBaseItemMap");
 271071
 271072                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271073                });
 1074
 271075            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Permission", b =>
 271076                {
 271077                    b.Property<int>("Id")
 271078                        .ValueGeneratedOnAdd()
 271079                        .HasColumnType("INTEGER");
 271080
 271081                    b.Property<int>("Kind")
 271082                        .HasColumnType("INTEGER");
 271083
 271084                    b.Property<Guid?>("Permission_Permissions_Guid")
 271085                        .HasColumnType("TEXT");
 271086
 271087                    b.Property<uint>("RowVersion")
 271088                        .IsConcurrencyToken()
 271089                        .HasColumnType("INTEGER");
 271090
 271091                    b.Property<Guid?>("UserId")
 271092                        .HasColumnType("TEXT");
 271093
 271094                    b.Property<bool>("Value")
 271095                        .HasColumnType("INTEGER");
 271096
 271097                    b.HasKey("Id");
 271098
 271099                    b.HasIndex("UserId", "Kind")
 271100                        .IsUnique()
 271101                        .HasFilter("[UserId] IS NOT NULL");
 271102
 271103                    b.ToTable("Permissions");
 271104
 271105                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271106                });
 1107
 271108            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Preference", b =>
 271109                {
 271110                    b.Property<int>("Id")
 271111                        .ValueGeneratedOnAdd()
 271112                        .HasColumnType("INTEGER");
 271113
 271114                    b.Property<int>("Kind")
 271115                        .HasColumnType("INTEGER");
 271116
 271117                    b.Property<Guid?>("Preference_Preferences_Guid")
 271118                        .HasColumnType("TEXT");
 271119
 271120                    b.Property<uint>("RowVersion")
 271121                        .IsConcurrencyToken()
 271122                        .HasColumnType("INTEGER");
 271123
 271124                    b.Property<Guid?>("UserId")
 271125                        .HasColumnType("TEXT");
 271126
 271127                    b.Property<string>("Value")
 271128                        .IsRequired()
 271129                        .HasMaxLength(65535)
 271130                        .HasColumnType("TEXT");
 271131
 271132                    b.HasKey("Id");
 271133
 271134                    b.HasIndex("UserId", "Kind")
 271135                        .IsUnique()
 271136                        .HasFilter("[UserId] IS NOT NULL");
 271137
 271138                    b.ToTable("Preferences");
 271139
 271140                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271141                });
 1142
 271143            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.ApiKey", b =>
 271144                {
 271145                    b.Property<int>("Id")
 271146                        .ValueGeneratedOnAdd()
 271147                        .HasColumnType("INTEGER");
 271148
 271149                    b.Property<string>("AccessToken")
 271150                        .IsRequired()
 271151                        .HasColumnType("TEXT");
 271152
 271153                    b.Property<DateTime>("DateCreated")
 271154                        .HasColumnType("TEXT");
 271155
 271156                    b.Property<DateTime>("DateLastActivity")
 271157                        .HasColumnType("TEXT");
 271158
 271159                    b.Property<string>("Name")
 271160                        .IsRequired()
 271161                        .HasMaxLength(64)
 271162                        .HasColumnType("TEXT");
 271163
 271164                    b.HasKey("Id");
 271165
 271166                    b.HasIndex("AccessToken")
 271167                        .IsUnique();
 271168
 271169                    b.ToTable("ApiKeys");
 271170
 271171                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271172                });
 1173
 271174            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.Device", b =>
 271175                {
 271176                    b.Property<int>("Id")
 271177                        .ValueGeneratedOnAdd()
 271178                        .HasColumnType("INTEGER");
 271179
 271180                    b.Property<string>("AccessToken")
 271181                        .IsRequired()
 271182                        .HasColumnType("TEXT");
 271183
 271184                    b.Property<string>("AppName")
 271185                        .IsRequired()
 271186                        .HasMaxLength(64)
 271187                        .HasColumnType("TEXT");
 271188
 271189                    b.Property<string>("AppVersion")
 271190                        .IsRequired()
 271191                        .HasMaxLength(32)
 271192                        .HasColumnType("TEXT");
 271193
 271194                    b.Property<DateTime>("DateCreated")
 271195                        .HasColumnType("TEXT");
 271196
 271197                    b.Property<DateTime>("DateLastActivity")
 271198                        .HasColumnType("TEXT");
 271199
 271200                    b.Property<DateTime>("DateModified")
 271201                        .HasColumnType("TEXT");
 271202
 271203                    b.Property<string>("DeviceId")
 271204                        .IsRequired()
 271205                        .HasMaxLength(256)
 271206                        .HasColumnType("TEXT");
 271207
 271208                    b.Property<string>("DeviceName")
 271209                        .IsRequired()
 271210                        .HasMaxLength(64)
 271211                        .HasColumnType("TEXT");
 271212
 271213                    b.Property<bool>("IsActive")
 271214                        .HasColumnType("INTEGER");
 271215
 271216                    b.Property<Guid>("UserId")
 271217                        .HasColumnType("TEXT");
 271218
 271219                    b.HasKey("Id");
 271220
 271221                    b.HasIndex("DeviceId");
 271222
 271223                    b.HasIndex("AccessToken", "DateLastActivity");
 271224
 271225                    b.HasIndex("DeviceId", "DateLastActivity");
 271226
 271227                    b.HasIndex("UserId", "DeviceId");
 271228
 271229                    b.ToTable("Devices");
 271230
 271231                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271232                });
 1233
 271234            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.DeviceOptions", b =>
 271235                {
 271236                    b.Property<int>("Id")
 271237                        .ValueGeneratedOnAdd()
 271238                        .HasColumnType("INTEGER");
 271239
 271240                    b.Property<string>("CustomName")
 271241                        .HasColumnType("TEXT");
 271242
 271243                    b.Property<string>("DeviceId")
 271244                        .IsRequired()
 271245                        .HasColumnType("TEXT");
 271246
 271247                    b.HasKey("Id");
 271248
 271249                    b.HasIndex("DeviceId")
 271250                        .IsUnique();
 271251
 271252                    b.ToTable("DeviceOptions");
 271253
 271254                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271255                });
 1256
 271257            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.TrickplayInfo", b =>
 271258                {
 271259                    b.Property<Guid>("ItemId")
 271260                        .HasColumnType("TEXT");
 271261
 271262                    b.Property<int>("Width")
 271263                        .HasColumnType("INTEGER");
 271264
 271265                    b.Property<int>("Bandwidth")
 271266                        .HasColumnType("INTEGER");
 271267
 271268                    b.Property<int>("Height")
 271269                        .HasColumnType("INTEGER");
 271270
 271271                    b.Property<int>("Interval")
 271272                        .HasColumnType("INTEGER");
 271273
 271274                    b.Property<int>("ThumbnailCount")
 271275                        .HasColumnType("INTEGER");
 271276
 271277                    b.Property<int>("TileHeight")
 271278                        .HasColumnType("INTEGER");
 271279
 271280                    b.Property<int>("TileWidth")
 271281                        .HasColumnType("INTEGER");
 271282
 271283                    b.HasKey("ItemId", "Width");
 271284
 271285                    b.ToTable("TrickplayInfos");
 271286
 271287                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271288                });
 1289
 271290            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.User", b =>
 271291                {
 271292                    b.Property<Guid>("Id")
 271293                        .ValueGeneratedOnAdd()
 271294                        .HasColumnType("TEXT");
 271295
 271296                    b.Property<string>("AudioLanguagePreference")
 271297                        .HasMaxLength(255)
 271298                        .HasColumnType("TEXT");
 271299
 271300                    b.Property<string>("AuthenticationProviderId")
 271301                        .IsRequired()
 271302                        .HasMaxLength(255)
 271303                        .HasColumnType("TEXT");
 271304
 271305                    b.Property<string>("CastReceiverId")
 271306                        .HasMaxLength(32)
 271307                        .HasColumnType("TEXT");
 271308
 271309                    b.Property<bool>("DisplayCollectionsView")
 271310                        .HasColumnType("INTEGER");
 271311
 271312                    b.Property<bool>("DisplayMissingEpisodes")
 271313                        .HasColumnType("INTEGER");
 271314
 271315                    b.Property<bool>("EnableAutoLogin")
 271316                        .HasColumnType("INTEGER");
 271317
 271318                    b.Property<bool>("EnableLocalPassword")
 271319                        .HasColumnType("INTEGER");
 271320
 271321                    b.Property<bool>("EnableNextEpisodeAutoPlay")
 271322                        .HasColumnType("INTEGER");
 271323
 271324                    b.Property<bool>("EnableUserPreferenceAccess")
 271325                        .HasColumnType("INTEGER");
 271326
 271327                    b.Property<bool>("HidePlayedInLatest")
 271328                        .HasColumnType("INTEGER");
 271329
 271330                    b.Property<long>("InternalId")
 271331                        .HasColumnType("INTEGER");
 271332
 271333                    b.Property<int>("InvalidLoginAttemptCount")
 271334                        .HasColumnType("INTEGER");
 271335
 271336                    b.Property<DateTime?>("LastActivityDate")
 271337                        .HasColumnType("TEXT");
 271338
 271339                    b.Property<DateTime?>("LastLoginDate")
 271340                        .HasColumnType("TEXT");
 271341
 271342                    b.Property<int?>("LoginAttemptsBeforeLockout")
 271343                        .HasColumnType("INTEGER");
 271344
 271345                    b.Property<int>("MaxActiveSessions")
 271346                        .HasColumnType("INTEGER");
 271347
 271348                    b.Property<int?>("MaxParentalRatingScore")
 271349                        .HasColumnType("INTEGER");
 271350
 271351                    b.Property<int?>("MaxParentalRatingSubScore")
 271352                        .HasColumnType("INTEGER");
 271353
 271354                    b.Property<bool>("MustUpdatePassword")
 271355                        .HasColumnType("INTEGER");
 271356
 271357                    b.Property<string>("Password")
 271358                        .HasMaxLength(65535)
 271359                        .HasColumnType("TEXT");
 271360
 271361                    b.Property<string>("PasswordResetProviderId")
 271362                        .IsRequired()
 271363                        .HasMaxLength(255)
 271364                        .HasColumnType("TEXT");
 271365
 271366                    b.Property<bool>("PlayDefaultAudioTrack")
 271367                        .HasColumnType("INTEGER");
 271368
 271369                    b.Property<bool>("RememberAudioSelections")
 271370                        .HasColumnType("INTEGER");
 271371
 271372                    b.Property<bool>("RememberSubtitleSelections")
 271373                        .HasColumnType("INTEGER");
 271374
 271375                    b.Property<int?>("RemoteClientBitrateLimit")
 271376                        .HasColumnType("INTEGER");
 271377
 271378                    b.Property<uint>("RowVersion")
 271379                        .IsConcurrencyToken()
 271380                        .HasColumnType("INTEGER");
 271381
 271382                    b.Property<string>("SubtitleLanguagePreference")
 271383                        .HasMaxLength(255)
 271384                        .HasColumnType("TEXT");
 271385
 271386                    b.Property<int>("SubtitleMode")
 271387                        .HasColumnType("INTEGER");
 271388
 271389                    b.Property<int>("SyncPlayAccess")
 271390                        .HasColumnType("INTEGER");
 271391
 271392                    b.Property<string>("Username")
 271393                        .IsRequired()
 271394                        .HasMaxLength(255)
 271395                        .HasColumnType("TEXT");
 271396
 271397                    b.HasKey("Id");
 271398
 271399                    b.HasIndex("Username")
 271400                        .IsUnique();
 271401
 271402                    b.ToTable("Users");
 271403
 271404                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271405                });
 1406
 271407            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.UserData", b =>
 271408                {
 271409                    b.Property<Guid>("ItemId")
 271410                        .HasColumnType("TEXT");
 271411
 271412                    b.Property<Guid>("UserId")
 271413                        .HasColumnType("TEXT");
 271414
 271415                    b.Property<string>("CustomDataKey")
 271416                        .HasColumnType("TEXT");
 271417
 271418                    b.Property<int?>("AudioStreamIndex")
 271419                        .HasColumnType("INTEGER");
 271420
 271421                    b.Property<bool>("IsFavorite")
 271422                        .HasColumnType("INTEGER");
 271423
 271424                    b.Property<DateTime?>("LastPlayedDate")
 271425                        .HasColumnType("TEXT");
 271426
 271427                    b.Property<bool?>("Likes")
 271428                        .HasColumnType("INTEGER");
 271429
 271430                    b.Property<int>("PlayCount")
 271431                        .HasColumnType("INTEGER");
 271432
 271433                    b.Property<long>("PlaybackPositionTicks")
 271434                        .HasColumnType("INTEGER");
 271435
 271436                    b.Property<bool>("Played")
 271437                        .HasColumnType("INTEGER");
 271438
 271439                    b.Property<double?>("Rating")
 271440                        .HasColumnType("REAL");
 271441
 271442                    b.Property<DateTime?>("RetentionDate")
 271443                        .HasColumnType("TEXT");
 271444
 271445                    b.Property<int?>("SubtitleStreamIndex")
 271446                        .HasColumnType("INTEGER");
 271447
 271448                    b.HasKey("ItemId", "UserId", "CustomDataKey");
 271449
 271450                    b.HasIndex("ItemId", "UserId", "IsFavorite");
 271451
 271452                    b.HasIndex("ItemId", "UserId", "LastPlayedDate");
 271453
 271454                    b.HasIndex("ItemId", "UserId", "PlaybackPositionTicks");
 271455
 271456                    b.HasIndex("ItemId", "UserId", "Played");
 271457
 271458                    b.HasIndex("UserId", "ItemId", "LastPlayedDate");
 271459
 271460                    b.ToTable("UserData");
 271461
 271462                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 271463                });
 1464
 271465            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AccessSchedule", b =>
 271466                {
 271467                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 271468                        .WithMany("AccessSchedules")
 271469                        .HasForeignKey("UserId")
 271470                        .OnDelete(DeleteBehavior.Cascade)
 271471                        .IsRequired();
 271472                });
 1473
 271474            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AncestorId", b =>
 271475                {
 271476                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271477                        .WithMany("Parents")
 271478                        .HasForeignKey("ItemId")
 271479                        .OnDelete(DeleteBehavior.Cascade)
 271480                        .IsRequired();
 271481
 271482                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "ParentItem")
 271483                        .WithMany("Children")
 271484                        .HasForeignKey("ParentItemId")
 271485                        .OnDelete(DeleteBehavior.Cascade)
 271486                        .IsRequired();
 271487
 271488                    b.Navigation("Item");
 271489
 271490                    b.Navigation("ParentItem");
 271491                });
 1492
 271493            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AttachmentStreamInfo", b =>
 271494                {
 271495                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271496                        .WithMany()
 271497                        .HasForeignKey("ItemId")
 271498                        .OnDelete(DeleteBehavior.Cascade)
 271499                        .IsRequired();
 271500
 271501                    b.Navigation("Item");
 271502                });
 1503
 271504            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemEntity", b =>
 271505                {
 271506                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Owner")
 271507                        .WithMany("Extras")
 271508                        .HasForeignKey("OwnerId")
 271509                        .OnDelete(DeleteBehavior.NoAction);
 271510
 271511                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "DirectParent")
 271512                        .WithMany("DirectChildren")
 271513                        .HasForeignKey("ParentId")
 271514                        .OnDelete(DeleteBehavior.Cascade);
 271515
 271516                    b.Navigation("DirectParent");
 271517
 271518                    b.Navigation("Owner");
 271519                });
 1520
 271521            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemImageInfo", b =>
 271522                {
 271523                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271524                        .WithMany("Images")
 271525                        .HasForeignKey("ItemId")
 271526                        .OnDelete(DeleteBehavior.Cascade)
 271527                        .IsRequired();
 271528
 271529                    b.Navigation("Item");
 271530                });
 1531
 271532            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemMetadataField", b =>
 271533                {
 271534                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271535                        .WithMany("LockedFields")
 271536                        .HasForeignKey("ItemId")
 271537                        .OnDelete(DeleteBehavior.Cascade)
 271538                        .IsRequired();
 271539
 271540                    b.Navigation("Item");
 271541                });
 1542
 271543            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemProvider", b =>
 271544                {
 271545                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271546                        .WithMany("Provider")
 271547                        .HasForeignKey("ItemId")
 271548                        .OnDelete(DeleteBehavior.Cascade)
 271549                        .IsRequired();
 271550
 271551                    b.Navigation("Item");
 271552                });
 1553
 271554            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemTrailerType", b =>
 271555                {
 271556                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271557                        .WithMany("TrailerTypes")
 271558                        .HasForeignKey("ItemId")
 271559                        .OnDelete(DeleteBehavior.Cascade)
 271560                        .IsRequired();
 271561
 271562                    b.Navigation("Item");
 271563                });
 1564
 271565            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Chapter", b =>
 271566                {
 271567                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271568                        .WithMany("Chapters")
 271569                        .HasForeignKey("ItemId")
 271570                        .OnDelete(DeleteBehavior.Cascade)
 271571                        .IsRequired();
 271572
 271573                    b.Navigation("Item");
 271574                });
 1575
 271576            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 271577                {
 271578                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 271579                        .WithMany("DisplayPreferences")
 271580                        .HasForeignKey("UserId")
 271581                        .OnDelete(DeleteBehavior.Cascade)
 271582                        .IsRequired();
 271583                });
 1584
 271585            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.HomeSection", b =>
 271586                {
 271587                    b.HasOne("Jellyfin.Database.Implementations.Entities.DisplayPreferences", null)
 271588                        .WithMany("HomeSections")
 271589                        .HasForeignKey("DisplayPreferencesId")
 271590                        .OnDelete(DeleteBehavior.Cascade)
 271591                        .IsRequired();
 271592                });
 1593
 271594            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ImageInfo", b =>
 271595                {
 271596                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 271597                        .WithOne("ProfileImage")
 271598                        .HasForeignKey("Jellyfin.Database.Implementations.Entities.ImageInfo", "UserId")
 271599                        .OnDelete(DeleteBehavior.Cascade);
 271600                });
 1601
 271602            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemDisplayPreferences", b =>
 271603                {
 271604                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 271605                        .WithMany("ItemDisplayPreferences")
 271606                        .HasForeignKey("UserId")
 271607                        .OnDelete(DeleteBehavior.Cascade)
 271608                        .IsRequired();
 271609                });
 1610
 271611            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValueMap", b =>
 271612                {
 271613                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271614                        .WithMany("ItemValues")
 271615                        .HasForeignKey("ItemId")
 271616                        .OnDelete(DeleteBehavior.Cascade)
 271617                        .IsRequired();
 271618
 271619                    b.HasOne("Jellyfin.Database.Implementations.Entities.ItemValue", "ItemValue")
 271620                        .WithMany("BaseItemsMap")
 271621                        .HasForeignKey("ItemValueId")
 271622                        .OnDelete(DeleteBehavior.Cascade)
 271623                        .IsRequired();
 271624
 271625                    b.Navigation("Item");
 271626
 271627                    b.Navigation("ItemValue");
 271628                });
 1629
 271630            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.KeyframeData", b =>
 271631                {
 271632                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271633                        .WithMany()
 271634                        .HasForeignKey("ItemId")
 271635                        .OnDelete(DeleteBehavior.Cascade)
 271636                        .IsRequired();
 271637
 271638                    b.Navigation("Item");
 271639                });
 1640
 271641            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.LinkedChildEntity", b =>
 271642                {
 271643                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Child")
 271644                        .WithMany("LinkedChildOfEntities")
 271645                        .HasForeignKey("ChildId")
 271646                        .OnDelete(DeleteBehavior.NoAction)
 271647                        .IsRequired();
 271648
 271649                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Parent")
 271650                        .WithMany("LinkedChildEntities")
 271651                        .HasForeignKey("ParentId")
 271652                        .OnDelete(DeleteBehavior.NoAction)
 271653                        .IsRequired();
 271654
 271655                    b.Navigation("Child");
 271656
 271657                    b.Navigation("Parent");
 271658                });
 1659
 271660            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaStreamInfo", b =>
 271661                {
 271662                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271663                        .WithMany("MediaStreams")
 271664                        .HasForeignKey("ItemId")
 271665                        .OnDelete(DeleteBehavior.Cascade)
 271666                        .IsRequired();
 271667
 271668                    b.Navigation("Item");
 271669                });
 1670
 271671            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.PeopleBaseItemMap", b =>
 271672                {
 271673                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271674                        .WithMany("Peoples")
 271675                        .HasForeignKey("ItemId")
 271676                        .OnDelete(DeleteBehavior.Cascade)
 271677                        .IsRequired();
 271678
 271679                    b.HasOne("Jellyfin.Database.Implementations.Entities.People", "People")
 271680                        .WithMany("BaseItems")
 271681                        .HasForeignKey("PeopleId")
 271682                        .OnDelete(DeleteBehavior.Cascade)
 271683                        .IsRequired();
 271684
 271685                    b.Navigation("Item");
 271686
 271687                    b.Navigation("People");
 271688                });
 1689
 271690            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Permission", b =>
 271691                {
 271692                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 271693                        .WithMany("Permissions")
 271694                        .HasForeignKey("UserId")
 271695                        .OnDelete(DeleteBehavior.Cascade);
 271696                });
 1697
 271698            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Preference", b =>
 271699                {
 271700                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 271701                        .WithMany("Preferences")
 271702                        .HasForeignKey("UserId")
 271703                        .OnDelete(DeleteBehavior.Cascade);
 271704                });
 1705
 271706            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.Device", b =>
 271707                {
 271708                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", "User")
 271709                        .WithMany()
 271710                        .HasForeignKey("UserId")
 271711                        .OnDelete(DeleteBehavior.Cascade)
 271712                        .IsRequired();
 271713
 271714                    b.Navigation("User");
 271715                });
 1716
 271717            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.UserData", b =>
 271718                {
 271719                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 271720                        .WithMany("UserData")
 271721                        .HasForeignKey("ItemId")
 271722                        .OnDelete(DeleteBehavior.Cascade)
 271723                        .IsRequired();
 271724
 271725                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", "User")
 271726                        .WithMany()
 271727                        .HasForeignKey("UserId")
 271728                        .OnDelete(DeleteBehavior.Cascade)
 271729                        .IsRequired();
 271730
 271731                    b.Navigation("Item");
 271732
 271733                    b.Navigation("User");
 271734                });
 1735
 271736            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemEntity", b =>
 271737                {
 271738                    b.Navigation("Chapters");
 271739
 271740                    b.Navigation("Children");
 271741
 271742                    b.Navigation("DirectChildren");
 271743
 271744                    b.Navigation("Extras");
 271745
 271746                    b.Navigation("Images");
 271747
 271748                    b.Navigation("ItemValues");
 271749
 271750                    b.Navigation("LinkedChildEntities");
 271751
 271752                    b.Navigation("LinkedChildOfEntities");
 271753
 271754                    b.Navigation("LockedFields");
 271755
 271756                    b.Navigation("MediaStreams");
 271757
 271758                    b.Navigation("Parents");
 271759
 271760                    b.Navigation("Peoples");
 271761
 271762                    b.Navigation("Provider");
 271763
 271764                    b.Navigation("TrailerTypes");
 271765
 271766                    b.Navigation("UserData");
 271767                });
 1768
 271769            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 271770                {
 271771                    b.Navigation("HomeSections");
 271772                });
 1773
 271774            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValue", b =>
 271775                {
 271776                    b.Navigation("BaseItemsMap");
 271777                });
 1778
 271779            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.People", b =>
 271780                {
 271781                    b.Navigation("BaseItems");
 271782                });
 1783
 271784            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.User", b =>
 271785                {
 271786                    b.Navigation("AccessSchedules");
 271787
 271788                    b.Navigation("DisplayPreferences");
 271789
 271790                    b.Navigation("ItemDisplayPreferences");
 271791
 271792                    b.Navigation("Permissions");
 271793
 271794                    b.Navigation("Preferences");
 271795
 271796                    b.Navigation("ProfileImage");
 271797                });
 1798#pragma warning restore 612, 618
 271799        }
 1800    }
 1801}