< Summary - Jellyfin

Line coverage
99%
Covered lines: 1639
Uncovered lines: 10
Coverable lines: 1649
Total lines: 1746
Line coverage: 99.3%
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

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/20250622170802_BaseItemImageInfoDateModifiedNullable.cs

#LineLine coverage
 1using System;
 2using Microsoft.EntityFrameworkCore.Migrations;
 3
 4#nullable disable
 5
 6namespace Jellyfin.Server.Implementations.Migrations
 7{
 8    /// <inheritdoc />
 9    public partial class BaseItemImageInfoDateModifiedNullable : Migration
 10    {
 11        /// <inheritdoc />
 12        protected override void Up(MigrationBuilder migrationBuilder)
 13        {
 2114            migrationBuilder.AlterColumn<DateTime>(
 2115                name: "DateModified",
 2116                table: "BaseItemImageInfos",
 2117                type: "TEXT",
 2118                nullable: true,
 2119                oldClrType: typeof(DateTime),
 2120                oldType: "TEXT");
 2121        }
 22
 23        /// <inheritdoc />
 24        protected override void Down(MigrationBuilder migrationBuilder)
 25        {
 026            migrationBuilder.AlterColumn<DateTime>(
 027                name: "DateModified",
 028                table: "BaseItemImageInfos",
 029                type: "TEXT",
 030                nullable: false,
 031                defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified),
 032                oldClrType: typeof(DateTime),
 033                oldType: "TEXT",
 034                oldNullable: true);
 035        }
 36    }
 37}

/srv/git/jellyfin/src/Jellyfin.Database/Jellyfin.Database.Providers.Sqlite/Migrations/20250622170802_BaseItemImageInfoDateModifiedNullable.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.Server.Implementations.Migrations
 12{
 13    [DbContext(typeof(JellyfinDbContext))]
 14    [Migration("20250622170802_BaseItemImageInfoDateModifiedNullable")]
 15    partial class BaseItemImageInfoDateModifiedNullable
 16    {
 17        /// <inheritdoc />
 18        protected override void BuildTargetModel(ModelBuilder modelBuilder)
 19        {
 20#pragma warning disable 612, 618
 2121            modelBuilder.HasAnnotation("ProductVersion", "9.0.6");
 22
 2123            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AccessSchedule", b =>
 2124                {
 2125                    b.Property<int>("Id")
 2126                        .ValueGeneratedOnAdd()
 2127                        .HasColumnType("INTEGER");
 2128
 2129                    b.Property<int>("DayOfWeek")
 2130                        .HasColumnType("INTEGER");
 2131
 2132                    b.Property<double>("EndHour")
 2133                        .HasColumnType("REAL");
 2134
 2135                    b.Property<double>("StartHour")
 2136                        .HasColumnType("REAL");
 2137
 2138                    b.Property<Guid>("UserId")
 2139                        .HasColumnType("TEXT");
 2140
 2141                    b.HasKey("Id");
 2142
 2143                    b.HasIndex("UserId");
 2144
 2145                    b.ToTable("AccessSchedules");
 2146
 2147                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 2148                });
 49
 2150            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ActivityLog", b =>
 2151                {
 2152                    b.Property<int>("Id")
 2153                        .ValueGeneratedOnAdd()
 2154                        .HasColumnType("INTEGER");
 2155
 2156                    b.Property<DateTime>("DateCreated")
 2157                        .HasColumnType("TEXT");
 2158
 2159                    b.Property<string>("ItemId")
 2160                        .HasMaxLength(256)
 2161                        .HasColumnType("TEXT");
 2162
 2163                    b.Property<int>("LogSeverity")
 2164                        .HasColumnType("INTEGER");
 2165
 2166                    b.Property<string>("Name")
 2167                        .IsRequired()
 2168                        .HasMaxLength(512)
 2169                        .HasColumnType("TEXT");
 2170
 2171                    b.Property<string>("Overview")
 2172                        .HasMaxLength(512)
 2173                        .HasColumnType("TEXT");
 2174
 2175                    b.Property<uint>("RowVersion")
 2176                        .IsConcurrencyToken()
 2177                        .HasColumnType("INTEGER");
 2178
 2179                    b.Property<string>("ShortOverview")
 2180                        .HasMaxLength(512)
 2181                        .HasColumnType("TEXT");
 2182
 2183                    b.Property<string>("Type")
 2184                        .IsRequired()
 2185                        .HasMaxLength(256)
 2186                        .HasColumnType("TEXT");
 2187
 2188                    b.Property<Guid>("UserId")
 2189                        .HasColumnType("TEXT");
 2190
 2191                    b.HasKey("Id");
 2192
 2193                    b.HasIndex("DateCreated");
 2194
 2195                    b.ToTable("ActivityLogs");
 2196
 2197                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 2198                });
 99
 21100            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AncestorId", b =>
 21101                {
 21102                    b.Property<Guid>("ItemId")
 21103                        .HasColumnType("TEXT");
 21104
 21105                    b.Property<Guid>("ParentItemId")
 21106                        .HasColumnType("TEXT");
 21107
 21108                    b.HasKey("ItemId", "ParentItemId");
 21109
 21110                    b.HasIndex("ParentItemId");
 21111
 21112                    b.ToTable("AncestorIds");
 21113
 21114                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21115                });
 116
 21117            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AttachmentStreamInfo", b =>
 21118                {
 21119                    b.Property<Guid>("ItemId")
 21120                        .HasColumnType("TEXT");
 21121
 21122                    b.Property<int>("Index")
 21123                        .HasColumnType("INTEGER");
 21124
 21125                    b.Property<string>("Codec")
 21126                        .HasColumnType("TEXT");
 21127
 21128                    b.Property<string>("CodecTag")
 21129                        .HasColumnType("TEXT");
 21130
 21131                    b.Property<string>("Comment")
 21132                        .HasColumnType("TEXT");
 21133
 21134                    b.Property<string>("Filename")
 21135                        .HasColumnType("TEXT");
 21136
 21137                    b.Property<string>("MimeType")
 21138                        .HasColumnType("TEXT");
 21139
 21140                    b.HasKey("ItemId", "Index");
 21141
 21142                    b.ToTable("AttachmentStreamInfos");
 21143
 21144                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21145                });
 146
 21147            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemEntity", b =>
 21148                {
 21149                    b.Property<Guid>("Id")
 21150                        .ValueGeneratedOnAdd()
 21151                        .HasColumnType("TEXT");
 21152
 21153                    b.Property<string>("Album")
 21154                        .HasColumnType("TEXT");
 21155
 21156                    b.Property<string>("AlbumArtists")
 21157                        .HasColumnType("TEXT");
 21158
 21159                    b.Property<string>("Artists")
 21160                        .HasColumnType("TEXT");
 21161
 21162                    b.Property<int?>("Audio")
 21163                        .HasColumnType("INTEGER");
 21164
 21165                    b.Property<Guid?>("ChannelId")
 21166                        .HasColumnType("TEXT");
 21167
 21168                    b.Property<string>("CleanName")
 21169                        .HasColumnType("TEXT");
 21170
 21171                    b.Property<float?>("CommunityRating")
 21172                        .HasColumnType("REAL");
 21173
 21174                    b.Property<float?>("CriticRating")
 21175                        .HasColumnType("REAL");
 21176
 21177                    b.Property<string>("CustomRating")
 21178                        .HasColumnType("TEXT");
 21179
 21180                    b.Property<string>("Data")
 21181                        .HasColumnType("TEXT");
 21182
 21183                    b.Property<DateTime?>("DateCreated")
 21184                        .HasColumnType("TEXT");
 21185
 21186                    b.Property<DateTime?>("DateLastMediaAdded")
 21187                        .HasColumnType("TEXT");
 21188
 21189                    b.Property<DateTime?>("DateLastRefreshed")
 21190                        .HasColumnType("TEXT");
 21191
 21192                    b.Property<DateTime?>("DateLastSaved")
 21193                        .HasColumnType("TEXT");
 21194
 21195                    b.Property<DateTime?>("DateModified")
 21196                        .HasColumnType("TEXT");
 21197
 21198                    b.Property<DateTime?>("EndDate")
 21199                        .HasColumnType("TEXT");
 21200
 21201                    b.Property<string>("EpisodeTitle")
 21202                        .HasColumnType("TEXT");
 21203
 21204                    b.Property<string>("ExternalId")
 21205                        .HasColumnType("TEXT");
 21206
 21207                    b.Property<string>("ExternalSeriesId")
 21208                        .HasColumnType("TEXT");
 21209
 21210                    b.Property<string>("ExternalServiceId")
 21211                        .HasColumnType("TEXT");
 21212
 21213                    b.Property<string>("ExtraIds")
 21214                        .HasColumnType("TEXT");
 21215
 21216                    b.Property<int?>("ExtraType")
 21217                        .HasColumnType("INTEGER");
 21218
 21219                    b.Property<string>("ForcedSortName")
 21220                        .HasColumnType("TEXT");
 21221
 21222                    b.Property<string>("Genres")
 21223                        .HasColumnType("TEXT");
 21224
 21225                    b.Property<int?>("Height")
 21226                        .HasColumnType("INTEGER");
 21227
 21228                    b.Property<int?>("IndexNumber")
 21229                        .HasColumnType("INTEGER");
 21230
 21231                    b.Property<int?>("InheritedParentalRatingSubValue")
 21232                        .HasColumnType("INTEGER");
 21233
 21234                    b.Property<int?>("InheritedParentalRatingValue")
 21235                        .HasColumnType("INTEGER");
 21236
 21237                    b.Property<bool>("IsFolder")
 21238                        .HasColumnType("INTEGER");
 21239
 21240                    b.Property<bool>("IsInMixedFolder")
 21241                        .HasColumnType("INTEGER");
 21242
 21243                    b.Property<bool>("IsLocked")
 21244                        .HasColumnType("INTEGER");
 21245
 21246                    b.Property<bool>("IsMovie")
 21247                        .HasColumnType("INTEGER");
 21248
 21249                    b.Property<bool>("IsRepeat")
 21250                        .HasColumnType("INTEGER");
 21251
 21252                    b.Property<bool>("IsSeries")
 21253                        .HasColumnType("INTEGER");
 21254
 21255                    b.Property<bool>("IsVirtualItem")
 21256                        .HasColumnType("INTEGER");
 21257
 21258                    b.Property<float?>("LUFS")
 21259                        .HasColumnType("REAL");
 21260
 21261                    b.Property<string>("MediaType")
 21262                        .HasColumnType("TEXT");
 21263
 21264                    b.Property<string>("Name")
 21265                        .HasColumnType("TEXT");
 21266
 21267                    b.Property<float?>("NormalizationGain")
 21268                        .HasColumnType("REAL");
 21269
 21270                    b.Property<string>("OfficialRating")
 21271                        .HasColumnType("TEXT");
 21272
 21273                    b.Property<string>("OriginalTitle")
 21274                        .HasColumnType("TEXT");
 21275
 21276                    b.Property<string>("Overview")
 21277                        .HasColumnType("TEXT");
 21278
 21279                    b.Property<string>("OwnerId")
 21280                        .HasColumnType("TEXT");
 21281
 21282                    b.Property<Guid?>("ParentId")
 21283                        .HasColumnType("TEXT");
 21284
 21285                    b.Property<int?>("ParentIndexNumber")
 21286                        .HasColumnType("INTEGER");
 21287
 21288                    b.Property<string>("Path")
 21289                        .HasColumnType("TEXT");
 21290
 21291                    b.Property<string>("PreferredMetadataCountryCode")
 21292                        .HasColumnType("TEXT");
 21293
 21294                    b.Property<string>("PreferredMetadataLanguage")
 21295                        .HasColumnType("TEXT");
 21296
 21297                    b.Property<DateTime?>("PremiereDate")
 21298                        .HasColumnType("TEXT");
 21299
 21300                    b.Property<string>("PresentationUniqueKey")
 21301                        .HasColumnType("TEXT");
 21302
 21303                    b.Property<string>("PrimaryVersionId")
 21304                        .HasColumnType("TEXT");
 21305
 21306                    b.Property<string>("ProductionLocations")
 21307                        .HasColumnType("TEXT");
 21308
 21309                    b.Property<int?>("ProductionYear")
 21310                        .HasColumnType("INTEGER");
 21311
 21312                    b.Property<long?>("RunTimeTicks")
 21313                        .HasColumnType("INTEGER");
 21314
 21315                    b.Property<Guid?>("SeasonId")
 21316                        .HasColumnType("TEXT");
 21317
 21318                    b.Property<string>("SeasonName")
 21319                        .HasColumnType("TEXT");
 21320
 21321                    b.Property<Guid?>("SeriesId")
 21322                        .HasColumnType("TEXT");
 21323
 21324                    b.Property<string>("SeriesName")
 21325                        .HasColumnType("TEXT");
 21326
 21327                    b.Property<string>("SeriesPresentationUniqueKey")
 21328                        .HasColumnType("TEXT");
 21329
 21330                    b.Property<string>("ShowId")
 21331                        .HasColumnType("TEXT");
 21332
 21333                    b.Property<long?>("Size")
 21334                        .HasColumnType("INTEGER");
 21335
 21336                    b.Property<string>("SortName")
 21337                        .HasColumnType("TEXT");
 21338
 21339                    b.Property<DateTime?>("StartDate")
 21340                        .HasColumnType("TEXT");
 21341
 21342                    b.Property<string>("Studios")
 21343                        .HasColumnType("TEXT");
 21344
 21345                    b.Property<string>("Tagline")
 21346                        .HasColumnType("TEXT");
 21347
 21348                    b.Property<string>("Tags")
 21349                        .HasColumnType("TEXT");
 21350
 21351                    b.Property<Guid?>("TopParentId")
 21352                        .HasColumnType("TEXT");
 21353
 21354                    b.Property<int?>("TotalBitrate")
 21355                        .HasColumnType("INTEGER");
 21356
 21357                    b.Property<string>("Type")
 21358                        .IsRequired()
 21359                        .HasColumnType("TEXT");
 21360
 21361                    b.Property<string>("UnratedType")
 21362                        .HasColumnType("TEXT");
 21363
 21364                    b.Property<int?>("Width")
 21365                        .HasColumnType("INTEGER");
 21366
 21367                    b.HasKey("Id");
 21368
 21369                    b.HasIndex("ParentId");
 21370
 21371                    b.HasIndex("Path");
 21372
 21373                    b.HasIndex("PresentationUniqueKey");
 21374
 21375                    b.HasIndex("TopParentId", "Id");
 21376
 21377                    b.HasIndex("Type", "TopParentId", "Id");
 21378
 21379                    b.HasIndex("Type", "TopParentId", "PresentationUniqueKey");
 21380
 21381                    b.HasIndex("Type", "TopParentId", "StartDate");
 21382
 21383                    b.HasIndex("Id", "Type", "IsFolder", "IsVirtualItem");
 21384
 21385                    b.HasIndex("MediaType", "TopParentId", "IsVirtualItem", "PresentationUniqueKey");
 21386
 21387                    b.HasIndex("Type", "SeriesPresentationUniqueKey", "IsFolder", "IsVirtualItem");
 21388
 21389                    b.HasIndex("Type", "SeriesPresentationUniqueKey", "PresentationUniqueKey", "SortName");
 21390
 21391                    b.HasIndex("IsFolder", "TopParentId", "IsVirtualItem", "PresentationUniqueKey", "DateCreated");
 21392
 21393                    b.HasIndex("Type", "TopParentId", "IsVirtualItem", "PresentationUniqueKey", "DateCreated");
 21394
 21395                    b.ToTable("BaseItems");
 21396
 21397                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21398
 21399                    b.HasData(
 21400                        new
 21401                        {
 21402                            Id = new Guid("00000000-0000-0000-0000-000000000001"),
 21403                            IsFolder = false,
 21404                            IsInMixedFolder = false,
 21405                            IsLocked = false,
 21406                            IsMovie = false,
 21407                            IsRepeat = false,
 21408                            IsSeries = false,
 21409                            IsVirtualItem = false,
 21410                            Name = "This is a placeholder item for UserData that has been detacted from its original ite
 21411                            Type = "PLACEHOLDER"
 21412                        });
 21413                });
 414
 21415            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemImageInfo", b =>
 21416                {
 21417                    b.Property<Guid>("Id")
 21418                        .ValueGeneratedOnAdd()
 21419                        .HasColumnType("TEXT");
 21420
 21421                    b.Property<byte[]>("Blurhash")
 21422                        .HasColumnType("BLOB");
 21423
 21424                    b.Property<DateTime?>("DateModified")
 21425                        .HasColumnType("TEXT");
 21426
 21427                    b.Property<int>("Height")
 21428                        .HasColumnType("INTEGER");
 21429
 21430                    b.Property<int>("ImageType")
 21431                        .HasColumnType("INTEGER");
 21432
 21433                    b.Property<Guid>("ItemId")
 21434                        .HasColumnType("TEXT");
 21435
 21436                    b.Property<string>("Path")
 21437                        .IsRequired()
 21438                        .HasColumnType("TEXT");
 21439
 21440                    b.Property<int>("Width")
 21441                        .HasColumnType("INTEGER");
 21442
 21443                    b.HasKey("Id");
 21444
 21445                    b.HasIndex("ItemId");
 21446
 21447                    b.ToTable("BaseItemImageInfos");
 21448
 21449                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21450                });
 451
 21452            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemMetadataField", b =>
 21453                {
 21454                    b.Property<int>("Id")
 21455                        .HasColumnType("INTEGER");
 21456
 21457                    b.Property<Guid>("ItemId")
 21458                        .HasColumnType("TEXT");
 21459
 21460                    b.HasKey("Id", "ItemId");
 21461
 21462                    b.HasIndex("ItemId");
 21463
 21464                    b.ToTable("BaseItemMetadataFields");
 21465
 21466                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21467                });
 468
 21469            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemProvider", b =>
 21470                {
 21471                    b.Property<Guid>("ItemId")
 21472                        .HasColumnType("TEXT");
 21473
 21474                    b.Property<string>("ProviderId")
 21475                        .HasColumnType("TEXT");
 21476
 21477                    b.Property<string>("ProviderValue")
 21478                        .IsRequired()
 21479                        .HasColumnType("TEXT");
 21480
 21481                    b.HasKey("ItemId", "ProviderId");
 21482
 21483                    b.HasIndex("ProviderId", "ProviderValue", "ItemId");
 21484
 21485                    b.ToTable("BaseItemProviders");
 21486
 21487                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21488                });
 489
 21490            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemTrailerType", b =>
 21491                {
 21492                    b.Property<int>("Id")
 21493                        .HasColumnType("INTEGER");
 21494
 21495                    b.Property<Guid>("ItemId")
 21496                        .HasColumnType("TEXT");
 21497
 21498                    b.HasKey("Id", "ItemId");
 21499
 21500                    b.HasIndex("ItemId");
 21501
 21502                    b.ToTable("BaseItemTrailerTypes");
 21503
 21504                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21505                });
 506
 21507            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Chapter", b =>
 21508                {
 21509                    b.Property<Guid>("ItemId")
 21510                        .HasColumnType("TEXT");
 21511
 21512                    b.Property<int>("ChapterIndex")
 21513                        .HasColumnType("INTEGER");
 21514
 21515                    b.Property<DateTime?>("ImageDateModified")
 21516                        .HasColumnType("TEXT");
 21517
 21518                    b.Property<string>("ImagePath")
 21519                        .HasColumnType("TEXT");
 21520
 21521                    b.Property<string>("Name")
 21522                        .HasColumnType("TEXT");
 21523
 21524                    b.Property<long>("StartPositionTicks")
 21525                        .HasColumnType("INTEGER");
 21526
 21527                    b.HasKey("ItemId", "ChapterIndex");
 21528
 21529                    b.ToTable("Chapters");
 21530
 21531                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21532                });
 533
 21534            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.CustomItemDisplayPreferences", b =>
 21535                {
 21536                    b.Property<int>("Id")
 21537                        .ValueGeneratedOnAdd()
 21538                        .HasColumnType("INTEGER");
 21539
 21540                    b.Property<string>("Client")
 21541                        .IsRequired()
 21542                        .HasMaxLength(32)
 21543                        .HasColumnType("TEXT");
 21544
 21545                    b.Property<Guid>("ItemId")
 21546                        .HasColumnType("TEXT");
 21547
 21548                    b.Property<string>("Key")
 21549                        .IsRequired()
 21550                        .HasColumnType("TEXT");
 21551
 21552                    b.Property<Guid>("UserId")
 21553                        .HasColumnType("TEXT");
 21554
 21555                    b.Property<string>("Value")
 21556                        .HasColumnType("TEXT");
 21557
 21558                    b.HasKey("Id");
 21559
 21560                    b.HasIndex("UserId", "ItemId", "Client", "Key")
 21561                        .IsUnique();
 21562
 21563                    b.ToTable("CustomItemDisplayPreferences");
 21564
 21565                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21566                });
 567
 21568            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 21569                {
 21570                    b.Property<int>("Id")
 21571                        .ValueGeneratedOnAdd()
 21572                        .HasColumnType("INTEGER");
 21573
 21574                    b.Property<int>("ChromecastVersion")
 21575                        .HasColumnType("INTEGER");
 21576
 21577                    b.Property<string>("Client")
 21578                        .IsRequired()
 21579                        .HasMaxLength(32)
 21580                        .HasColumnType("TEXT");
 21581
 21582                    b.Property<string>("DashboardTheme")
 21583                        .HasMaxLength(32)
 21584                        .HasColumnType("TEXT");
 21585
 21586                    b.Property<bool>("EnableNextVideoInfoOverlay")
 21587                        .HasColumnType("INTEGER");
 21588
 21589                    b.Property<int?>("IndexBy")
 21590                        .HasColumnType("INTEGER");
 21591
 21592                    b.Property<Guid>("ItemId")
 21593                        .HasColumnType("TEXT");
 21594
 21595                    b.Property<int>("ScrollDirection")
 21596                        .HasColumnType("INTEGER");
 21597
 21598                    b.Property<bool>("ShowBackdrop")
 21599                        .HasColumnType("INTEGER");
 21600
 21601                    b.Property<bool>("ShowSidebar")
 21602                        .HasColumnType("INTEGER");
 21603
 21604                    b.Property<int>("SkipBackwardLength")
 21605                        .HasColumnType("INTEGER");
 21606
 21607                    b.Property<int>("SkipForwardLength")
 21608                        .HasColumnType("INTEGER");
 21609
 21610                    b.Property<string>("TvHome")
 21611                        .HasMaxLength(32)
 21612                        .HasColumnType("TEXT");
 21613
 21614                    b.Property<Guid>("UserId")
 21615                        .HasColumnType("TEXT");
 21616
 21617                    b.HasKey("Id");
 21618
 21619                    b.HasIndex("UserId", "ItemId", "Client")
 21620                        .IsUnique();
 21621
 21622                    b.ToTable("DisplayPreferences");
 21623
 21624                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21625                });
 626
 21627            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.HomeSection", b =>
 21628                {
 21629                    b.Property<int>("Id")
 21630                        .ValueGeneratedOnAdd()
 21631                        .HasColumnType("INTEGER");
 21632
 21633                    b.Property<int>("DisplayPreferencesId")
 21634                        .HasColumnType("INTEGER");
 21635
 21636                    b.Property<int>("Order")
 21637                        .HasColumnType("INTEGER");
 21638
 21639                    b.Property<int>("Type")
 21640                        .HasColumnType("INTEGER");
 21641
 21642                    b.HasKey("Id");
 21643
 21644                    b.HasIndex("DisplayPreferencesId");
 21645
 21646                    b.ToTable("HomeSection");
 21647
 21648                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21649                });
 650
 21651            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ImageInfo", b =>
 21652                {
 21653                    b.Property<int>("Id")
 21654                        .ValueGeneratedOnAdd()
 21655                        .HasColumnType("INTEGER");
 21656
 21657                    b.Property<DateTime>("LastModified")
 21658                        .HasColumnType("TEXT");
 21659
 21660                    b.Property<string>("Path")
 21661                        .IsRequired()
 21662                        .HasMaxLength(512)
 21663                        .HasColumnType("TEXT");
 21664
 21665                    b.Property<Guid?>("UserId")
 21666                        .HasColumnType("TEXT");
 21667
 21668                    b.HasKey("Id");
 21669
 21670                    b.HasIndex("UserId")
 21671                        .IsUnique();
 21672
 21673                    b.ToTable("ImageInfos");
 21674
 21675                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21676                });
 677
 21678            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemDisplayPreferences", b =>
 21679                {
 21680                    b.Property<int>("Id")
 21681                        .ValueGeneratedOnAdd()
 21682                        .HasColumnType("INTEGER");
 21683
 21684                    b.Property<string>("Client")
 21685                        .IsRequired()
 21686                        .HasMaxLength(32)
 21687                        .HasColumnType("TEXT");
 21688
 21689                    b.Property<int?>("IndexBy")
 21690                        .HasColumnType("INTEGER");
 21691
 21692                    b.Property<Guid>("ItemId")
 21693                        .HasColumnType("TEXT");
 21694
 21695                    b.Property<bool>("RememberIndexing")
 21696                        .HasColumnType("INTEGER");
 21697
 21698                    b.Property<bool>("RememberSorting")
 21699                        .HasColumnType("INTEGER");
 21700
 21701                    b.Property<string>("SortBy")
 21702                        .IsRequired()
 21703                        .HasMaxLength(64)
 21704                        .HasColumnType("TEXT");
 21705
 21706                    b.Property<int>("SortOrder")
 21707                        .HasColumnType("INTEGER");
 21708
 21709                    b.Property<Guid>("UserId")
 21710                        .HasColumnType("TEXT");
 21711
 21712                    b.Property<int>("ViewType")
 21713                        .HasColumnType("INTEGER");
 21714
 21715                    b.HasKey("Id");
 21716
 21717                    b.HasIndex("UserId");
 21718
 21719                    b.ToTable("ItemDisplayPreferences");
 21720
 21721                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21722                });
 723
 21724            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValue", b =>
 21725                {
 21726                    b.Property<Guid>("ItemValueId")
 21727                        .ValueGeneratedOnAdd()
 21728                        .HasColumnType("TEXT");
 21729
 21730                    b.Property<string>("CleanValue")
 21731                        .IsRequired()
 21732                        .HasColumnType("TEXT");
 21733
 21734                    b.Property<int>("Type")
 21735                        .HasColumnType("INTEGER");
 21736
 21737                    b.Property<string>("Value")
 21738                        .IsRequired()
 21739                        .HasColumnType("TEXT");
 21740
 21741                    b.HasKey("ItemValueId");
 21742
 21743                    b.HasIndex("Type", "CleanValue");
 21744
 21745                    b.HasIndex("Type", "Value")
 21746                        .IsUnique();
 21747
 21748                    b.ToTable("ItemValues");
 21749
 21750                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21751                });
 752
 21753            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValueMap", b =>
 21754                {
 21755                    b.Property<Guid>("ItemValueId")
 21756                        .HasColumnType("TEXT");
 21757
 21758                    b.Property<Guid>("ItemId")
 21759                        .HasColumnType("TEXT");
 21760
 21761                    b.HasKey("ItemValueId", "ItemId");
 21762
 21763                    b.HasIndex("ItemId");
 21764
 21765                    b.ToTable("ItemValuesMap");
 21766
 21767                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21768                });
 769
 21770            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.KeyframeData", b =>
 21771                {
 21772                    b.Property<Guid>("ItemId")
 21773                        .HasColumnType("TEXT");
 21774
 21775                    b.PrimitiveCollection<string>("KeyframeTicks")
 21776                        .HasColumnType("TEXT");
 21777
 21778                    b.Property<long>("TotalDuration")
 21779                        .HasColumnType("INTEGER");
 21780
 21781                    b.HasKey("ItemId");
 21782
 21783                    b.ToTable("KeyframeData");
 21784
 21785                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21786                });
 787
 21788            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaSegment", b =>
 21789                {
 21790                    b.Property<Guid>("Id")
 21791                        .ValueGeneratedOnAdd()
 21792                        .HasColumnType("TEXT");
 21793
 21794                    b.Property<long>("EndTicks")
 21795                        .HasColumnType("INTEGER");
 21796
 21797                    b.Property<Guid>("ItemId")
 21798                        .HasColumnType("TEXT");
 21799
 21800                    b.Property<string>("SegmentProviderId")
 21801                        .IsRequired()
 21802                        .HasColumnType("TEXT");
 21803
 21804                    b.Property<long>("StartTicks")
 21805                        .HasColumnType("INTEGER");
 21806
 21807                    b.Property<int>("Type")
 21808                        .HasColumnType("INTEGER");
 21809
 21810                    b.HasKey("Id");
 21811
 21812                    b.ToTable("MediaSegments");
 21813
 21814                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21815                });
 816
 21817            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaStreamInfo", b =>
 21818                {
 21819                    b.Property<Guid>("ItemId")
 21820                        .HasColumnType("TEXT");
 21821
 21822                    b.Property<int>("StreamIndex")
 21823                        .HasColumnType("INTEGER");
 21824
 21825                    b.Property<string>("AspectRatio")
 21826                        .HasColumnType("TEXT");
 21827
 21828                    b.Property<float?>("AverageFrameRate")
 21829                        .HasColumnType("REAL");
 21830
 21831                    b.Property<int?>("BitDepth")
 21832                        .HasColumnType("INTEGER");
 21833
 21834                    b.Property<int?>("BitRate")
 21835                        .HasColumnType("INTEGER");
 21836
 21837                    b.Property<int?>("BlPresentFlag")
 21838                        .HasColumnType("INTEGER");
 21839
 21840                    b.Property<string>("ChannelLayout")
 21841                        .HasColumnType("TEXT");
 21842
 21843                    b.Property<int?>("Channels")
 21844                        .HasColumnType("INTEGER");
 21845
 21846                    b.Property<string>("Codec")
 21847                        .HasColumnType("TEXT");
 21848
 21849                    b.Property<string>("CodecTag")
 21850                        .HasColumnType("TEXT");
 21851
 21852                    b.Property<string>("CodecTimeBase")
 21853                        .HasColumnType("TEXT");
 21854
 21855                    b.Property<string>("ColorPrimaries")
 21856                        .HasColumnType("TEXT");
 21857
 21858                    b.Property<string>("ColorSpace")
 21859                        .HasColumnType("TEXT");
 21860
 21861                    b.Property<string>("ColorTransfer")
 21862                        .HasColumnType("TEXT");
 21863
 21864                    b.Property<string>("Comment")
 21865                        .HasColumnType("TEXT");
 21866
 21867                    b.Property<int?>("DvBlSignalCompatibilityId")
 21868                        .HasColumnType("INTEGER");
 21869
 21870                    b.Property<int?>("DvLevel")
 21871                        .HasColumnType("INTEGER");
 21872
 21873                    b.Property<int?>("DvProfile")
 21874                        .HasColumnType("INTEGER");
 21875
 21876                    b.Property<int?>("DvVersionMajor")
 21877                        .HasColumnType("INTEGER");
 21878
 21879                    b.Property<int?>("DvVersionMinor")
 21880                        .HasColumnType("INTEGER");
 21881
 21882                    b.Property<int?>("ElPresentFlag")
 21883                        .HasColumnType("INTEGER");
 21884
 21885                    b.Property<bool?>("Hdr10PlusPresentFlag")
 21886                        .HasColumnType("INTEGER");
 21887
 21888                    b.Property<int?>("Height")
 21889                        .HasColumnType("INTEGER");
 21890
 21891                    b.Property<bool?>("IsAnamorphic")
 21892                        .HasColumnType("INTEGER");
 21893
 21894                    b.Property<bool?>("IsAvc")
 21895                        .HasColumnType("INTEGER");
 21896
 21897                    b.Property<bool>("IsDefault")
 21898                        .HasColumnType("INTEGER");
 21899
 21900                    b.Property<bool>("IsExternal")
 21901                        .HasColumnType("INTEGER");
 21902
 21903                    b.Property<bool>("IsForced")
 21904                        .HasColumnType("INTEGER");
 21905
 21906                    b.Property<bool?>("IsHearingImpaired")
 21907                        .HasColumnType("INTEGER");
 21908
 21909                    b.Property<bool?>("IsInterlaced")
 21910                        .HasColumnType("INTEGER");
 21911
 21912                    b.Property<string>("KeyFrames")
 21913                        .HasColumnType("TEXT");
 21914
 21915                    b.Property<string>("Language")
 21916                        .HasColumnType("TEXT");
 21917
 21918                    b.Property<float?>("Level")
 21919                        .HasColumnType("REAL");
 21920
 21921                    b.Property<string>("NalLengthSize")
 21922                        .HasColumnType("TEXT");
 21923
 21924                    b.Property<string>("Path")
 21925                        .HasColumnType("TEXT");
 21926
 21927                    b.Property<string>("PixelFormat")
 21928                        .HasColumnType("TEXT");
 21929
 21930                    b.Property<string>("Profile")
 21931                        .HasColumnType("TEXT");
 21932
 21933                    b.Property<float?>("RealFrameRate")
 21934                        .HasColumnType("REAL");
 21935
 21936                    b.Property<int?>("RefFrames")
 21937                        .HasColumnType("INTEGER");
 21938
 21939                    b.Property<int?>("Rotation")
 21940                        .HasColumnType("INTEGER");
 21941
 21942                    b.Property<int?>("RpuPresentFlag")
 21943                        .HasColumnType("INTEGER");
 21944
 21945                    b.Property<int?>("SampleRate")
 21946                        .HasColumnType("INTEGER");
 21947
 21948                    b.Property<int>("StreamType")
 21949                        .HasColumnType("INTEGER");
 21950
 21951                    b.Property<string>("TimeBase")
 21952                        .HasColumnType("TEXT");
 21953
 21954                    b.Property<string>("Title")
 21955                        .HasColumnType("TEXT");
 21956
 21957                    b.Property<int?>("Width")
 21958                        .HasColumnType("INTEGER");
 21959
 21960                    b.HasKey("ItemId", "StreamIndex");
 21961
 21962                    b.HasIndex("StreamIndex");
 21963
 21964                    b.HasIndex("StreamType");
 21965
 21966                    b.HasIndex("StreamIndex", "StreamType");
 21967
 21968                    b.HasIndex("StreamIndex", "StreamType", "Language");
 21969
 21970                    b.ToTable("MediaStreamInfos");
 21971
 21972                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21973                });
 974
 21975            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.People", b =>
 21976                {
 21977                    b.Property<Guid>("Id")
 21978                        .ValueGeneratedOnAdd()
 21979                        .HasColumnType("TEXT");
 21980
 21981                    b.Property<string>("Name")
 21982                        .IsRequired()
 21983                        .HasColumnType("TEXT");
 21984
 21985                    b.Property<string>("PersonType")
 21986                        .HasColumnType("TEXT");
 21987
 21988                    b.HasKey("Id");
 21989
 21990                    b.HasIndex("Name");
 21991
 21992                    b.ToTable("Peoples");
 21993
 21994                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 21995                });
 996
 21997            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.PeopleBaseItemMap", b =>
 21998                {
 21999                    b.Property<Guid>("ItemId")
 211000                        .HasColumnType("TEXT");
 211001
 211002                    b.Property<Guid>("PeopleId")
 211003                        .HasColumnType("TEXT");
 211004
 211005                    b.Property<int?>("ListOrder")
 211006                        .HasColumnType("INTEGER");
 211007
 211008                    b.Property<string>("Role")
 211009                        .HasColumnType("TEXT");
 211010
 211011                    b.Property<int?>("SortOrder")
 211012                        .HasColumnType("INTEGER");
 211013
 211014                    b.HasKey("ItemId", "PeopleId");
 211015
 211016                    b.HasIndex("PeopleId");
 211017
 211018                    b.HasIndex("ItemId", "ListOrder");
 211019
 211020                    b.HasIndex("ItemId", "SortOrder");
 211021
 211022                    b.ToTable("PeopleBaseItemMap");
 211023
 211024                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211025                });
 1026
 211027            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Permission", b =>
 211028                {
 211029                    b.Property<int>("Id")
 211030                        .ValueGeneratedOnAdd()
 211031                        .HasColumnType("INTEGER");
 211032
 211033                    b.Property<int>("Kind")
 211034                        .HasColumnType("INTEGER");
 211035
 211036                    b.Property<Guid?>("Permission_Permissions_Guid")
 211037                        .HasColumnType("TEXT");
 211038
 211039                    b.Property<uint>("RowVersion")
 211040                        .IsConcurrencyToken()
 211041                        .HasColumnType("INTEGER");
 211042
 211043                    b.Property<Guid?>("UserId")
 211044                        .HasColumnType("TEXT");
 211045
 211046                    b.Property<bool>("Value")
 211047                        .HasColumnType("INTEGER");
 211048
 211049                    b.HasKey("Id");
 211050
 211051                    b.HasIndex("UserId", "Kind")
 211052                        .IsUnique()
 211053                        .HasFilter("[UserId] IS NOT NULL");
 211054
 211055                    b.ToTable("Permissions");
 211056
 211057                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211058                });
 1059
 211060            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Preference", b =>
 211061                {
 211062                    b.Property<int>("Id")
 211063                        .ValueGeneratedOnAdd()
 211064                        .HasColumnType("INTEGER");
 211065
 211066                    b.Property<int>("Kind")
 211067                        .HasColumnType("INTEGER");
 211068
 211069                    b.Property<Guid?>("Preference_Preferences_Guid")
 211070                        .HasColumnType("TEXT");
 211071
 211072                    b.Property<uint>("RowVersion")
 211073                        .IsConcurrencyToken()
 211074                        .HasColumnType("INTEGER");
 211075
 211076                    b.Property<Guid?>("UserId")
 211077                        .HasColumnType("TEXT");
 211078
 211079                    b.Property<string>("Value")
 211080                        .IsRequired()
 211081                        .HasMaxLength(65535)
 211082                        .HasColumnType("TEXT");
 211083
 211084                    b.HasKey("Id");
 211085
 211086                    b.HasIndex("UserId", "Kind")
 211087                        .IsUnique()
 211088                        .HasFilter("[UserId] IS NOT NULL");
 211089
 211090                    b.ToTable("Preferences");
 211091
 211092                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211093                });
 1094
 211095            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.ApiKey", b =>
 211096                {
 211097                    b.Property<int>("Id")
 211098                        .ValueGeneratedOnAdd()
 211099                        .HasColumnType("INTEGER");
 211100
 211101                    b.Property<string>("AccessToken")
 211102                        .IsRequired()
 211103                        .HasColumnType("TEXT");
 211104
 211105                    b.Property<DateTime>("DateCreated")
 211106                        .HasColumnType("TEXT");
 211107
 211108                    b.Property<DateTime>("DateLastActivity")
 211109                        .HasColumnType("TEXT");
 211110
 211111                    b.Property<string>("Name")
 211112                        .IsRequired()
 211113                        .HasMaxLength(64)
 211114                        .HasColumnType("TEXT");
 211115
 211116                    b.HasKey("Id");
 211117
 211118                    b.HasIndex("AccessToken")
 211119                        .IsUnique();
 211120
 211121                    b.ToTable("ApiKeys");
 211122
 211123                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211124                });
 1125
 211126            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.Device", b =>
 211127                {
 211128                    b.Property<int>("Id")
 211129                        .ValueGeneratedOnAdd()
 211130                        .HasColumnType("INTEGER");
 211131
 211132                    b.Property<string>("AccessToken")
 211133                        .IsRequired()
 211134                        .HasColumnType("TEXT");
 211135
 211136                    b.Property<string>("AppName")
 211137                        .IsRequired()
 211138                        .HasMaxLength(64)
 211139                        .HasColumnType("TEXT");
 211140
 211141                    b.Property<string>("AppVersion")
 211142                        .IsRequired()
 211143                        .HasMaxLength(32)
 211144                        .HasColumnType("TEXT");
 211145
 211146                    b.Property<DateTime>("DateCreated")
 211147                        .HasColumnType("TEXT");
 211148
 211149                    b.Property<DateTime>("DateLastActivity")
 211150                        .HasColumnType("TEXT");
 211151
 211152                    b.Property<DateTime>("DateModified")
 211153                        .HasColumnType("TEXT");
 211154
 211155                    b.Property<string>("DeviceId")
 211156                        .IsRequired()
 211157                        .HasMaxLength(256)
 211158                        .HasColumnType("TEXT");
 211159
 211160                    b.Property<string>("DeviceName")
 211161                        .IsRequired()
 211162                        .HasMaxLength(64)
 211163                        .HasColumnType("TEXT");
 211164
 211165                    b.Property<bool>("IsActive")
 211166                        .HasColumnType("INTEGER");
 211167
 211168                    b.Property<Guid>("UserId")
 211169                        .HasColumnType("TEXT");
 211170
 211171                    b.HasKey("Id");
 211172
 211173                    b.HasIndex("DeviceId");
 211174
 211175                    b.HasIndex("AccessToken", "DateLastActivity");
 211176
 211177                    b.HasIndex("DeviceId", "DateLastActivity");
 211178
 211179                    b.HasIndex("UserId", "DeviceId");
 211180
 211181                    b.ToTable("Devices");
 211182
 211183                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211184                });
 1185
 211186            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.DeviceOptions", b =>
 211187                {
 211188                    b.Property<int>("Id")
 211189                        .ValueGeneratedOnAdd()
 211190                        .HasColumnType("INTEGER");
 211191
 211192                    b.Property<string>("CustomName")
 211193                        .HasColumnType("TEXT");
 211194
 211195                    b.Property<string>("DeviceId")
 211196                        .IsRequired()
 211197                        .HasColumnType("TEXT");
 211198
 211199                    b.HasKey("Id");
 211200
 211201                    b.HasIndex("DeviceId")
 211202                        .IsUnique();
 211203
 211204                    b.ToTable("DeviceOptions");
 211205
 211206                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211207                });
 1208
 211209            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.TrickplayInfo", b =>
 211210                {
 211211                    b.Property<Guid>("ItemId")
 211212                        .HasColumnType("TEXT");
 211213
 211214                    b.Property<int>("Width")
 211215                        .HasColumnType("INTEGER");
 211216
 211217                    b.Property<int>("Bandwidth")
 211218                        .HasColumnType("INTEGER");
 211219
 211220                    b.Property<int>("Height")
 211221                        .HasColumnType("INTEGER");
 211222
 211223                    b.Property<int>("Interval")
 211224                        .HasColumnType("INTEGER");
 211225
 211226                    b.Property<int>("ThumbnailCount")
 211227                        .HasColumnType("INTEGER");
 211228
 211229                    b.Property<int>("TileHeight")
 211230                        .HasColumnType("INTEGER");
 211231
 211232                    b.Property<int>("TileWidth")
 211233                        .HasColumnType("INTEGER");
 211234
 211235                    b.HasKey("ItemId", "Width");
 211236
 211237                    b.ToTable("TrickplayInfos");
 211238
 211239                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211240                });
 1241
 211242            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.User", b =>
 211243                {
 211244                    b.Property<Guid>("Id")
 211245                        .ValueGeneratedOnAdd()
 211246                        .HasColumnType("TEXT");
 211247
 211248                    b.Property<string>("AudioLanguagePreference")
 211249                        .HasMaxLength(255)
 211250                        .HasColumnType("TEXT");
 211251
 211252                    b.Property<string>("AuthenticationProviderId")
 211253                        .IsRequired()
 211254                        .HasMaxLength(255)
 211255                        .HasColumnType("TEXT");
 211256
 211257                    b.Property<string>("CastReceiverId")
 211258                        .HasMaxLength(32)
 211259                        .HasColumnType("TEXT");
 211260
 211261                    b.Property<bool>("DisplayCollectionsView")
 211262                        .HasColumnType("INTEGER");
 211263
 211264                    b.Property<bool>("DisplayMissingEpisodes")
 211265                        .HasColumnType("INTEGER");
 211266
 211267                    b.Property<bool>("EnableAutoLogin")
 211268                        .HasColumnType("INTEGER");
 211269
 211270                    b.Property<bool>("EnableLocalPassword")
 211271                        .HasColumnType("INTEGER");
 211272
 211273                    b.Property<bool>("EnableNextEpisodeAutoPlay")
 211274                        .HasColumnType("INTEGER");
 211275
 211276                    b.Property<bool>("EnableUserPreferenceAccess")
 211277                        .HasColumnType("INTEGER");
 211278
 211279                    b.Property<bool>("HidePlayedInLatest")
 211280                        .HasColumnType("INTEGER");
 211281
 211282                    b.Property<long>("InternalId")
 211283                        .HasColumnType("INTEGER");
 211284
 211285                    b.Property<int>("InvalidLoginAttemptCount")
 211286                        .HasColumnType("INTEGER");
 211287
 211288                    b.Property<DateTime?>("LastActivityDate")
 211289                        .HasColumnType("TEXT");
 211290
 211291                    b.Property<DateTime?>("LastLoginDate")
 211292                        .HasColumnType("TEXT");
 211293
 211294                    b.Property<int?>("LoginAttemptsBeforeLockout")
 211295                        .HasColumnType("INTEGER");
 211296
 211297                    b.Property<int>("MaxActiveSessions")
 211298                        .HasColumnType("INTEGER");
 211299
 211300                    b.Property<int?>("MaxParentalRatingScore")
 211301                        .HasColumnType("INTEGER");
 211302
 211303                    b.Property<int?>("MaxParentalRatingSubScore")
 211304                        .HasColumnType("INTEGER");
 211305
 211306                    b.Property<bool>("MustUpdatePassword")
 211307                        .HasColumnType("INTEGER");
 211308
 211309                    b.Property<string>("Password")
 211310                        .HasMaxLength(65535)
 211311                        .HasColumnType("TEXT");
 211312
 211313                    b.Property<string>("PasswordResetProviderId")
 211314                        .IsRequired()
 211315                        .HasMaxLength(255)
 211316                        .HasColumnType("TEXT");
 211317
 211318                    b.Property<bool>("PlayDefaultAudioTrack")
 211319                        .HasColumnType("INTEGER");
 211320
 211321                    b.Property<bool>("RememberAudioSelections")
 211322                        .HasColumnType("INTEGER");
 211323
 211324                    b.Property<bool>("RememberSubtitleSelections")
 211325                        .HasColumnType("INTEGER");
 211326
 211327                    b.Property<int?>("RemoteClientBitrateLimit")
 211328                        .HasColumnType("INTEGER");
 211329
 211330                    b.Property<uint>("RowVersion")
 211331                        .IsConcurrencyToken()
 211332                        .HasColumnType("INTEGER");
 211333
 211334                    b.Property<string>("SubtitleLanguagePreference")
 211335                        .HasMaxLength(255)
 211336                        .HasColumnType("TEXT");
 211337
 211338                    b.Property<int>("SubtitleMode")
 211339                        .HasColumnType("INTEGER");
 211340
 211341                    b.Property<int>("SyncPlayAccess")
 211342                        .HasColumnType("INTEGER");
 211343
 211344                    b.Property<string>("Username")
 211345                        .IsRequired()
 211346                        .HasMaxLength(255)
 211347                        .HasColumnType("TEXT");
 211348
 211349                    b.HasKey("Id");
 211350
 211351                    b.HasIndex("Username")
 211352                        .IsUnique();
 211353
 211354                    b.ToTable("Users");
 211355
 211356                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211357                });
 1358
 211359            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.UserData", b =>
 211360                {
 211361                    b.Property<Guid>("ItemId")
 211362                        .HasColumnType("TEXT");
 211363
 211364                    b.Property<Guid>("UserId")
 211365                        .HasColumnType("TEXT");
 211366
 211367                    b.Property<string>("CustomDataKey")
 211368                        .HasColumnType("TEXT");
 211369
 211370                    b.Property<int?>("AudioStreamIndex")
 211371                        .HasColumnType("INTEGER");
 211372
 211373                    b.Property<bool>("IsFavorite")
 211374                        .HasColumnType("INTEGER");
 211375
 211376                    b.Property<DateTime?>("LastPlayedDate")
 211377                        .HasColumnType("TEXT");
 211378
 211379                    b.Property<bool?>("Likes")
 211380                        .HasColumnType("INTEGER");
 211381
 211382                    b.Property<int>("PlayCount")
 211383                        .HasColumnType("INTEGER");
 211384
 211385                    b.Property<long>("PlaybackPositionTicks")
 211386                        .HasColumnType("INTEGER");
 211387
 211388                    b.Property<bool>("Played")
 211389                        .HasColumnType("INTEGER");
 211390
 211391                    b.Property<double?>("Rating")
 211392                        .HasColumnType("REAL");
 211393
 211394                    b.Property<DateTime?>("RetentionDate")
 211395                        .HasColumnType("TEXT");
 211396
 211397                    b.Property<int?>("SubtitleStreamIndex")
 211398                        .HasColumnType("INTEGER");
 211399
 211400                    b.HasKey("ItemId", "UserId", "CustomDataKey");
 211401
 211402                    b.HasIndex("UserId");
 211403
 211404                    b.HasIndex("ItemId", "UserId", "IsFavorite");
 211405
 211406                    b.HasIndex("ItemId", "UserId", "LastPlayedDate");
 211407
 211408                    b.HasIndex("ItemId", "UserId", "PlaybackPositionTicks");
 211409
 211410                    b.HasIndex("ItemId", "UserId", "Played");
 211411
 211412                    b.ToTable("UserData");
 211413
 211414                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 211415                });
 1416
 211417            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AccessSchedule", b =>
 211418                {
 211419                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 211420                        .WithMany("AccessSchedules")
 211421                        .HasForeignKey("UserId")
 211422                        .OnDelete(DeleteBehavior.Cascade)
 211423                        .IsRequired();
 211424                });
 1425
 211426            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AncestorId", b =>
 211427                {
 211428                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211429                        .WithMany("Parents")
 211430                        .HasForeignKey("ItemId")
 211431                        .OnDelete(DeleteBehavior.Cascade)
 211432                        .IsRequired();
 211433
 211434                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "ParentItem")
 211435                        .WithMany("Children")
 211436                        .HasForeignKey("ParentItemId")
 211437                        .OnDelete(DeleteBehavior.Cascade)
 211438                        .IsRequired();
 211439
 211440                    b.Navigation("Item");
 211441
 211442                    b.Navigation("ParentItem");
 211443                });
 1444
 211445            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AttachmentStreamInfo", b =>
 211446                {
 211447                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211448                        .WithMany()
 211449                        .HasForeignKey("ItemId")
 211450                        .OnDelete(DeleteBehavior.Cascade)
 211451                        .IsRequired();
 211452
 211453                    b.Navigation("Item");
 211454                });
 1455
 211456            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemImageInfo", b =>
 211457                {
 211458                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211459                        .WithMany("Images")
 211460                        .HasForeignKey("ItemId")
 211461                        .OnDelete(DeleteBehavior.Cascade)
 211462                        .IsRequired();
 211463
 211464                    b.Navigation("Item");
 211465                });
 1466
 211467            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemMetadataField", b =>
 211468                {
 211469                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211470                        .WithMany("LockedFields")
 211471                        .HasForeignKey("ItemId")
 211472                        .OnDelete(DeleteBehavior.Cascade)
 211473                        .IsRequired();
 211474
 211475                    b.Navigation("Item");
 211476                });
 1477
 211478            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemProvider", b =>
 211479                {
 211480                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211481                        .WithMany("Provider")
 211482                        .HasForeignKey("ItemId")
 211483                        .OnDelete(DeleteBehavior.Cascade)
 211484                        .IsRequired();
 211485
 211486                    b.Navigation("Item");
 211487                });
 1488
 211489            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemTrailerType", b =>
 211490                {
 211491                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211492                        .WithMany("TrailerTypes")
 211493                        .HasForeignKey("ItemId")
 211494                        .OnDelete(DeleteBehavior.Cascade)
 211495                        .IsRequired();
 211496
 211497                    b.Navigation("Item");
 211498                });
 1499
 211500            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Chapter", b =>
 211501                {
 211502                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211503                        .WithMany("Chapters")
 211504                        .HasForeignKey("ItemId")
 211505                        .OnDelete(DeleteBehavior.Cascade)
 211506                        .IsRequired();
 211507
 211508                    b.Navigation("Item");
 211509                });
 1510
 211511            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 211512                {
 211513                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 211514                        .WithMany("DisplayPreferences")
 211515                        .HasForeignKey("UserId")
 211516                        .OnDelete(DeleteBehavior.Cascade)
 211517                        .IsRequired();
 211518                });
 1519
 211520            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.HomeSection", b =>
 211521                {
 211522                    b.HasOne("Jellyfin.Database.Implementations.Entities.DisplayPreferences", null)
 211523                        .WithMany("HomeSections")
 211524                        .HasForeignKey("DisplayPreferencesId")
 211525                        .OnDelete(DeleteBehavior.Cascade)
 211526                        .IsRequired();
 211527                });
 1528
 211529            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ImageInfo", b =>
 211530                {
 211531                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 211532                        .WithOne("ProfileImage")
 211533                        .HasForeignKey("Jellyfin.Database.Implementations.Entities.ImageInfo", "UserId")
 211534                        .OnDelete(DeleteBehavior.Cascade);
 211535                });
 1536
 211537            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemDisplayPreferences", b =>
 211538                {
 211539                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 211540                        .WithMany("ItemDisplayPreferences")
 211541                        .HasForeignKey("UserId")
 211542                        .OnDelete(DeleteBehavior.Cascade)
 211543                        .IsRequired();
 211544                });
 1545
 211546            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValueMap", b =>
 211547                {
 211548                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211549                        .WithMany("ItemValues")
 211550                        .HasForeignKey("ItemId")
 211551                        .OnDelete(DeleteBehavior.Cascade)
 211552                        .IsRequired();
 211553
 211554                    b.HasOne("Jellyfin.Database.Implementations.Entities.ItemValue", "ItemValue")
 211555                        .WithMany("BaseItemsMap")
 211556                        .HasForeignKey("ItemValueId")
 211557                        .OnDelete(DeleteBehavior.Cascade)
 211558                        .IsRequired();
 211559
 211560                    b.Navigation("Item");
 211561
 211562                    b.Navigation("ItemValue");
 211563                });
 1564
 211565            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.KeyframeData", b =>
 211566                {
 211567                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211568                        .WithMany()
 211569                        .HasForeignKey("ItemId")
 211570                        .OnDelete(DeleteBehavior.Cascade)
 211571                        .IsRequired();
 211572
 211573                    b.Navigation("Item");
 211574                });
 1575
 211576            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaStreamInfo", b =>
 211577                {
 211578                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211579                        .WithMany("MediaStreams")
 211580                        .HasForeignKey("ItemId")
 211581                        .OnDelete(DeleteBehavior.Cascade)
 211582                        .IsRequired();
 211583
 211584                    b.Navigation("Item");
 211585                });
 1586
 211587            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.PeopleBaseItemMap", b =>
 211588                {
 211589                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211590                        .WithMany("Peoples")
 211591                        .HasForeignKey("ItemId")
 211592                        .OnDelete(DeleteBehavior.Cascade)
 211593                        .IsRequired();
 211594
 211595                    b.HasOne("Jellyfin.Database.Implementations.Entities.People", "People")
 211596                        .WithMany("BaseItems")
 211597                        .HasForeignKey("PeopleId")
 211598                        .OnDelete(DeleteBehavior.Cascade)
 211599                        .IsRequired();
 211600
 211601                    b.Navigation("Item");
 211602
 211603                    b.Navigation("People");
 211604                });
 1605
 211606            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Permission", b =>
 211607                {
 211608                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 211609                        .WithMany("Permissions")
 211610                        .HasForeignKey("UserId")
 211611                        .OnDelete(DeleteBehavior.Cascade);
 211612                });
 1613
 211614            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Preference", b =>
 211615                {
 211616                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 211617                        .WithMany("Preferences")
 211618                        .HasForeignKey("UserId")
 211619                        .OnDelete(DeleteBehavior.Cascade);
 211620                });
 1621
 211622            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.Device", b =>
 211623                {
 211624                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", "User")
 211625                        .WithMany()
 211626                        .HasForeignKey("UserId")
 211627                        .OnDelete(DeleteBehavior.Cascade)
 211628                        .IsRequired();
 211629
 211630                    b.Navigation("User");
 211631                });
 1632
 211633            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.UserData", b =>
 211634                {
 211635                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 211636                        .WithMany("UserData")
 211637                        .HasForeignKey("ItemId")
 211638                        .OnDelete(DeleteBehavior.Cascade)
 211639                        .IsRequired();
 211640
 211641                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", "User")
 211642                        .WithMany()
 211643                        .HasForeignKey("UserId")
 211644                        .OnDelete(DeleteBehavior.Cascade)
 211645                        .IsRequired();
 211646
 211647                    b.Navigation("Item");
 211648
 211649                    b.Navigation("User");
 211650                });
 1651
 211652            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemEntity", b =>
 211653                {
 211654                    b.Navigation("Chapters");
 211655
 211656                    b.Navigation("Children");
 211657
 211658                    b.Navigation("Images");
 211659
 211660                    b.Navigation("ItemValues");
 211661
 211662                    b.Navigation("LockedFields");
 211663
 211664                    b.Navigation("MediaStreams");
 211665
 211666                    b.Navigation("Parents");
 211667
 211668                    b.Navigation("Peoples");
 211669
 211670                    b.Navigation("Provider");
 211671
 211672                    b.Navigation("TrailerTypes");
 211673
 211674                    b.Navigation("UserData");
 211675                });
 1676
 211677            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 211678                {
 211679                    b.Navigation("HomeSections");
 211680                });
 1681
 211682            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValue", b =>
 211683                {
 211684                    b.Navigation("BaseItemsMap");
 211685                });
 1686
 211687            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.People", b =>
 211688                {
 211689                    b.Navigation("BaseItems");
 211690                });
 1691
 211692            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.User", b =>
 211693                {
 211694                    b.Navigation("AccessSchedules");
 211695
 211696                    b.Navigation("DisplayPreferences");
 211697
 211698                    b.Navigation("ItemDisplayPreferences");
 211699
 211700                    b.Navigation("Permissions");
 211701
 211702                    b.Navigation("Preferences");
 211703
 211704                    b.Navigation("ProfileImage");
 211705                });
 1706#pragma warning restore 612, 618
 211707        }
 1708    }
 1709}