< Summary - Jellyfin

Line coverage
99%
Covered lines: 1612
Uncovered lines: 1
Coverable lines: 1613
Total lines: 1709
Line coverage: 99.9%
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/6/2026 - 12:15:23 AM Line coverage: 99.9% (1583/1584) Total lines: 16788/11/2026 - 12:17:00 AM Line coverage: 99.9% (1612/1613) Total lines: 1709

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/20250401142247_FixAncestors.cs

#LineLine coverage
 1using Microsoft.EntityFrameworkCore.Migrations;
 2
 3#nullable disable
 4
 5namespace Jellyfin.Server.Implementations.Migrations
 6{
 7    /// <inheritdoc />
 8    public partial class FixAncestors : Migration
 9    {
 10        /// <inheritdoc />
 11        protected override void Up(MigrationBuilder migrationBuilder)
 12        {
 2213        }
 14
 15        /// <inheritdoc />
 16        protected override void Down(MigrationBuilder migrationBuilder)
 17        {
 018        }
 19    }
 20}

/srv/git/jellyfin/src/Jellyfin.Database/Jellyfin.Database.Providers.Sqlite/Migrations/20250401142247_FixAncestors.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("20250401142247_FixAncestors")]
 15    partial class FixAncestors
 16    {
 17        /// <inheritdoc />
 18        protected override void BuildTargetModel(ModelBuilder modelBuilder)
 19        {
 20#pragma warning disable 612, 618
 2221            modelBuilder.HasAnnotation("ProductVersion", "9.0.3");
 22
 2223            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AccessSchedule", b =>
 2224                {
 2225                    b.Property<int>("Id")
 2226                        .ValueGeneratedOnAdd()
 2227                        .HasColumnType("INTEGER");
 2228
 2229                    b.Property<int>("DayOfWeek")
 2230                        .HasColumnType("INTEGER");
 2231
 2232                    b.Property<double>("EndHour")
 2233                        .HasColumnType("REAL");
 2234
 2235                    b.Property<double>("StartHour")
 2236                        .HasColumnType("REAL");
 2237
 2238                    b.Property<Guid>("UserId")
 2239                        .HasColumnType("TEXT");
 2240
 2241                    b.HasKey("Id");
 2242
 2243                    b.HasIndex("UserId");
 2244
 2245                    b.ToTable("AccessSchedules");
 2246
 2247                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 2248                });
 49
 2250            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ActivityLog", b =>
 2251                {
 2252                    b.Property<int>("Id")
 2253                        .ValueGeneratedOnAdd()
 2254                        .HasColumnType("INTEGER");
 2255
 2256                    b.Property<DateTime>("DateCreated")
 2257                        .HasColumnType("TEXT");
 2258
 2259                    b.Property<string>("ItemId")
 2260                        .HasMaxLength(256)
 2261                        .HasColumnType("TEXT");
 2262
 2263                    b.Property<int>("LogSeverity")
 2264                        .HasColumnType("INTEGER");
 2265
 2266                    b.Property<string>("Name")
 2267                        .IsRequired()
 2268                        .HasMaxLength(512)
 2269                        .HasColumnType("TEXT");
 2270
 2271                    b.Property<string>("Overview")
 2272                        .HasMaxLength(512)
 2273                        .HasColumnType("TEXT");
 2274
 2275                    b.Property<uint>("RowVersion")
 2276                        .IsConcurrencyToken()
 2277                        .HasColumnType("INTEGER");
 2278
 2279                    b.Property<string>("ShortOverview")
 2280                        .HasMaxLength(512)
 2281                        .HasColumnType("TEXT");
 2282
 2283                    b.Property<string>("Type")
 2284                        .IsRequired()
 2285                        .HasMaxLength(256)
 2286                        .HasColumnType("TEXT");
 2287
 2288                    b.Property<Guid>("UserId")
 2289                        .HasColumnType("TEXT");
 2290
 2291                    b.HasKey("Id");
 2292
 2293                    b.HasIndex("DateCreated");
 2294
 2295                    b.ToTable("ActivityLogs");
 2296
 2297                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 2298                });
 99
 22100            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AncestorId", b =>
 22101                {
 22102                    b.Property<Guid>("ItemId")
 22103                        .HasColumnType("TEXT");
 22104
 22105                    b.Property<Guid>("ParentItemId")
 22106                        .HasColumnType("TEXT");
 22107
 22108                    b.HasKey("ItemId", "ParentItemId");
 22109
 22110                    b.HasIndex("ParentItemId");
 22111
 22112                    b.ToTable("AncestorIds");
 22113
 22114                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22115                });
 116
 22117            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AttachmentStreamInfo", b =>
 22118                {
 22119                    b.Property<Guid>("ItemId")
 22120                        .HasColumnType("TEXT");
 22121
 22122                    b.Property<int>("Index")
 22123                        .HasColumnType("INTEGER");
 22124
 22125                    b.Property<string>("Codec")
 22126                        .HasColumnType("TEXT");
 22127
 22128                    b.Property<string>("CodecTag")
 22129                        .HasColumnType("TEXT");
 22130
 22131                    b.Property<string>("Comment")
 22132                        .HasColumnType("TEXT");
 22133
 22134                    b.Property<string>("Filename")
 22135                        .HasColumnType("TEXT");
 22136
 22137                    b.Property<string>("MimeType")
 22138                        .HasColumnType("TEXT");
 22139
 22140                    b.HasKey("ItemId", "Index");
 22141
 22142                    b.ToTable("AttachmentStreamInfos");
 22143
 22144                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22145                });
 146
 22147            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemEntity", b =>
 22148                {
 22149                    b.Property<Guid>("Id")
 22150                        .ValueGeneratedOnAdd()
 22151                        .HasColumnType("TEXT");
 22152
 22153                    b.Property<string>("Album")
 22154                        .HasColumnType("TEXT");
 22155
 22156                    b.Property<string>("AlbumArtists")
 22157                        .HasColumnType("TEXT");
 22158
 22159                    b.Property<string>("Artists")
 22160                        .HasColumnType("TEXT");
 22161
 22162                    b.Property<int?>("Audio")
 22163                        .HasColumnType("INTEGER");
 22164
 22165                    b.Property<Guid?>("ChannelId")
 22166                        .HasColumnType("TEXT");
 22167
 22168                    b.Property<string>("CleanName")
 22169                        .HasColumnType("TEXT");
 22170
 22171                    b.Property<float?>("CommunityRating")
 22172                        .HasColumnType("REAL");
 22173
 22174                    b.Property<float?>("CriticRating")
 22175                        .HasColumnType("REAL");
 22176
 22177                    b.Property<string>("CustomRating")
 22178                        .HasColumnType("TEXT");
 22179
 22180                    b.Property<string>("Data")
 22181                        .HasColumnType("TEXT");
 22182
 22183                    b.Property<DateTime?>("DateCreated")
 22184                        .HasColumnType("TEXT");
 22185
 22186                    b.Property<DateTime?>("DateLastMediaAdded")
 22187                        .HasColumnType("TEXT");
 22188
 22189                    b.Property<DateTime?>("DateLastRefreshed")
 22190                        .HasColumnType("TEXT");
 22191
 22192                    b.Property<DateTime?>("DateLastSaved")
 22193                        .HasColumnType("TEXT");
 22194
 22195                    b.Property<DateTime?>("DateModified")
 22196                        .HasColumnType("TEXT");
 22197
 22198                    b.Property<DateTime?>("EndDate")
 22199                        .HasColumnType("TEXT");
 22200
 22201                    b.Property<string>("EpisodeTitle")
 22202                        .HasColumnType("TEXT");
 22203
 22204                    b.Property<string>("ExternalId")
 22205                        .HasColumnType("TEXT");
 22206
 22207                    b.Property<string>("ExternalSeriesId")
 22208                        .HasColumnType("TEXT");
 22209
 22210                    b.Property<string>("ExternalServiceId")
 22211                        .HasColumnType("TEXT");
 22212
 22213                    b.Property<string>("ExtraIds")
 22214                        .HasColumnType("TEXT");
 22215
 22216                    b.Property<int?>("ExtraType")
 22217                        .HasColumnType("INTEGER");
 22218
 22219                    b.Property<string>("ForcedSortName")
 22220                        .HasColumnType("TEXT");
 22221
 22222                    b.Property<string>("Genres")
 22223                        .HasColumnType("TEXT");
 22224
 22225                    b.Property<int?>("Height")
 22226                        .HasColumnType("INTEGER");
 22227
 22228                    b.Property<int?>("IndexNumber")
 22229                        .HasColumnType("INTEGER");
 22230
 22231                    b.Property<int?>("InheritedParentalRatingSubValue")
 22232                        .HasColumnType("INTEGER");
 22233
 22234                    b.Property<int?>("InheritedParentalRatingValue")
 22235                        .HasColumnType("INTEGER");
 22236
 22237                    b.Property<bool>("IsFolder")
 22238                        .HasColumnType("INTEGER");
 22239
 22240                    b.Property<bool>("IsInMixedFolder")
 22241                        .HasColumnType("INTEGER");
 22242
 22243                    b.Property<bool>("IsLocked")
 22244                        .HasColumnType("INTEGER");
 22245
 22246                    b.Property<bool>("IsMovie")
 22247                        .HasColumnType("INTEGER");
 22248
 22249                    b.Property<bool>("IsRepeat")
 22250                        .HasColumnType("INTEGER");
 22251
 22252                    b.Property<bool>("IsSeries")
 22253                        .HasColumnType("INTEGER");
 22254
 22255                    b.Property<bool>("IsVirtualItem")
 22256                        .HasColumnType("INTEGER");
 22257
 22258                    b.Property<float?>("LUFS")
 22259                        .HasColumnType("REAL");
 22260
 22261                    b.Property<string>("MediaType")
 22262                        .HasColumnType("TEXT");
 22263
 22264                    b.Property<string>("Name")
 22265                        .HasColumnType("TEXT");
 22266
 22267                    b.Property<float?>("NormalizationGain")
 22268                        .HasColumnType("REAL");
 22269
 22270                    b.Property<string>("OfficialRating")
 22271                        .HasColumnType("TEXT");
 22272
 22273                    b.Property<string>("OriginalTitle")
 22274                        .HasColumnType("TEXT");
 22275
 22276                    b.Property<string>("Overview")
 22277                        .HasColumnType("TEXT");
 22278
 22279                    b.Property<string>("OwnerId")
 22280                        .HasColumnType("TEXT");
 22281
 22282                    b.Property<Guid?>("ParentId")
 22283                        .HasColumnType("TEXT");
 22284
 22285                    b.Property<int?>("ParentIndexNumber")
 22286                        .HasColumnType("INTEGER");
 22287
 22288                    b.Property<string>("Path")
 22289                        .HasColumnType("TEXT");
 22290
 22291                    b.Property<string>("PreferredMetadataCountryCode")
 22292                        .HasColumnType("TEXT");
 22293
 22294                    b.Property<string>("PreferredMetadataLanguage")
 22295                        .HasColumnType("TEXT");
 22296
 22297                    b.Property<DateTime?>("PremiereDate")
 22298                        .HasColumnType("TEXT");
 22299
 22300                    b.Property<string>("PresentationUniqueKey")
 22301                        .HasColumnType("TEXT");
 22302
 22303                    b.Property<string>("PrimaryVersionId")
 22304                        .HasColumnType("TEXT");
 22305
 22306                    b.Property<string>("ProductionLocations")
 22307                        .HasColumnType("TEXT");
 22308
 22309                    b.Property<int?>("ProductionYear")
 22310                        .HasColumnType("INTEGER");
 22311
 22312                    b.Property<long?>("RunTimeTicks")
 22313                        .HasColumnType("INTEGER");
 22314
 22315                    b.Property<Guid?>("SeasonId")
 22316                        .HasColumnType("TEXT");
 22317
 22318                    b.Property<string>("SeasonName")
 22319                        .HasColumnType("TEXT");
 22320
 22321                    b.Property<Guid?>("SeriesId")
 22322                        .HasColumnType("TEXT");
 22323
 22324                    b.Property<string>("SeriesName")
 22325                        .HasColumnType("TEXT");
 22326
 22327                    b.Property<string>("SeriesPresentationUniqueKey")
 22328                        .HasColumnType("TEXT");
 22329
 22330                    b.Property<string>("ShowId")
 22331                        .HasColumnType("TEXT");
 22332
 22333                    b.Property<long?>("Size")
 22334                        .HasColumnType("INTEGER");
 22335
 22336                    b.Property<string>("SortName")
 22337                        .HasColumnType("TEXT");
 22338
 22339                    b.Property<DateTime?>("StartDate")
 22340                        .HasColumnType("TEXT");
 22341
 22342                    b.Property<string>("Studios")
 22343                        .HasColumnType("TEXT");
 22344
 22345                    b.Property<string>("Tagline")
 22346                        .HasColumnType("TEXT");
 22347
 22348                    b.Property<string>("Tags")
 22349                        .HasColumnType("TEXT");
 22350
 22351                    b.Property<Guid?>("TopParentId")
 22352                        .HasColumnType("TEXT");
 22353
 22354                    b.Property<int?>("TotalBitrate")
 22355                        .HasColumnType("INTEGER");
 22356
 22357                    b.Property<string>("Type")
 22358                        .IsRequired()
 22359                        .HasColumnType("TEXT");
 22360
 22361                    b.Property<string>("UnratedType")
 22362                        .HasColumnType("TEXT");
 22363
 22364                    b.Property<int?>("Width")
 22365                        .HasColumnType("INTEGER");
 22366
 22367                    b.HasKey("Id");
 22368
 22369                    b.HasIndex("ParentId");
 22370
 22371                    b.HasIndex("Path");
 22372
 22373                    b.HasIndex("PresentationUniqueKey");
 22374
 22375                    b.HasIndex("TopParentId", "Id");
 22376
 22377                    b.HasIndex("Type", "TopParentId", "Id");
 22378
 22379                    b.HasIndex("Type", "TopParentId", "PresentationUniqueKey");
 22380
 22381                    b.HasIndex("Type", "TopParentId", "StartDate");
 22382
 22383                    b.HasIndex("Id", "Type", "IsFolder", "IsVirtualItem");
 22384
 22385                    b.HasIndex("MediaType", "TopParentId", "IsVirtualItem", "PresentationUniqueKey");
 22386
 22387                    b.HasIndex("Type", "SeriesPresentationUniqueKey", "IsFolder", "IsVirtualItem");
 22388
 22389                    b.HasIndex("Type", "SeriesPresentationUniqueKey", "PresentationUniqueKey", "SortName");
 22390
 22391                    b.HasIndex("IsFolder", "TopParentId", "IsVirtualItem", "PresentationUniqueKey", "DateCreated");
 22392
 22393                    b.HasIndex("Type", "TopParentId", "IsVirtualItem", "PresentationUniqueKey", "DateCreated");
 22394
 22395                    b.ToTable("BaseItems");
 22396
 22397                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22398                });
 399
 22400            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemImageInfo", b =>
 22401                {
 22402                    b.Property<Guid>("Id")
 22403                        .ValueGeneratedOnAdd()
 22404                        .HasColumnType("TEXT");
 22405
 22406                    b.Property<byte[]>("Blurhash")
 22407                        .HasColumnType("BLOB");
 22408
 22409                    b.Property<DateTime>("DateModified")
 22410                        .HasColumnType("TEXT");
 22411
 22412                    b.Property<int>("Height")
 22413                        .HasColumnType("INTEGER");
 22414
 22415                    b.Property<int>("ImageType")
 22416                        .HasColumnType("INTEGER");
 22417
 22418                    b.Property<Guid>("ItemId")
 22419                        .HasColumnType("TEXT");
 22420
 22421                    b.Property<string>("Path")
 22422                        .IsRequired()
 22423                        .HasColumnType("TEXT");
 22424
 22425                    b.Property<int>("Width")
 22426                        .HasColumnType("INTEGER");
 22427
 22428                    b.HasKey("Id");
 22429
 22430                    b.HasIndex("ItemId");
 22431
 22432                    b.ToTable("BaseItemImageInfos");
 22433
 22434                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22435                });
 436
 22437            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemMetadataField", b =>
 22438                {
 22439                    b.Property<int>("Id")
 22440                        .HasColumnType("INTEGER");
 22441
 22442                    b.Property<Guid>("ItemId")
 22443                        .HasColumnType("TEXT");
 22444
 22445                    b.HasKey("Id", "ItemId");
 22446
 22447                    b.HasIndex("ItemId");
 22448
 22449                    b.ToTable("BaseItemMetadataFields");
 22450
 22451                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22452                });
 453
 22454            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemProvider", b =>
 22455                {
 22456                    b.Property<Guid>("ItemId")
 22457                        .HasColumnType("TEXT");
 22458
 22459                    b.Property<string>("ProviderId")
 22460                        .HasColumnType("TEXT");
 22461
 22462                    b.Property<string>("ProviderValue")
 22463                        .IsRequired()
 22464                        .HasColumnType("TEXT");
 22465
 22466                    b.HasKey("ItemId", "ProviderId");
 22467
 22468                    b.HasIndex("ProviderId", "ProviderValue", "ItemId");
 22469
 22470                    b.ToTable("BaseItemProviders");
 22471
 22472                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22473                });
 474
 22475            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemTrailerType", b =>
 22476                {
 22477                    b.Property<int>("Id")
 22478                        .HasColumnType("INTEGER");
 22479
 22480                    b.Property<Guid>("ItemId")
 22481                        .HasColumnType("TEXT");
 22482
 22483                    b.HasKey("Id", "ItemId");
 22484
 22485                    b.HasIndex("ItemId");
 22486
 22487                    b.ToTable("BaseItemTrailerTypes");
 22488
 22489                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22490                });
 491
 22492            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Chapter", b =>
 22493                {
 22494                    b.Property<Guid>("ItemId")
 22495                        .HasColumnType("TEXT");
 22496
 22497                    b.Property<int>("ChapterIndex")
 22498                        .HasColumnType("INTEGER");
 22499
 22500                    b.Property<DateTime?>("ImageDateModified")
 22501                        .HasColumnType("TEXT");
 22502
 22503                    b.Property<string>("ImagePath")
 22504                        .HasColumnType("TEXT");
 22505
 22506                    b.Property<string>("Name")
 22507                        .HasColumnType("TEXT");
 22508
 22509                    b.Property<long>("StartPositionTicks")
 22510                        .HasColumnType("INTEGER");
 22511
 22512                    b.HasKey("ItemId", "ChapterIndex");
 22513
 22514                    b.ToTable("Chapters");
 22515
 22516                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22517                });
 518
 22519            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.CustomItemDisplayPreferences", b =>
 22520                {
 22521                    b.Property<int>("Id")
 22522                        .ValueGeneratedOnAdd()
 22523                        .HasColumnType("INTEGER");
 22524
 22525                    b.Property<string>("Client")
 22526                        .IsRequired()
 22527                        .HasMaxLength(32)
 22528                        .HasColumnType("TEXT");
 22529
 22530                    b.Property<Guid>("ItemId")
 22531                        .HasColumnType("TEXT");
 22532
 22533                    b.Property<string>("Key")
 22534                        .IsRequired()
 22535                        .HasColumnType("TEXT");
 22536
 22537                    b.Property<Guid>("UserId")
 22538                        .HasColumnType("TEXT");
 22539
 22540                    b.Property<string>("Value")
 22541                        .HasColumnType("TEXT");
 22542
 22543                    b.HasKey("Id");
 22544
 22545                    b.HasIndex("UserId", "ItemId", "Client", "Key")
 22546                        .IsUnique();
 22547
 22548                    b.ToTable("CustomItemDisplayPreferences");
 22549
 22550                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22551                });
 552
 22553            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 22554                {
 22555                    b.Property<int>("Id")
 22556                        .ValueGeneratedOnAdd()
 22557                        .HasColumnType("INTEGER");
 22558
 22559                    b.Property<int>("ChromecastVersion")
 22560                        .HasColumnType("INTEGER");
 22561
 22562                    b.Property<string>("Client")
 22563                        .IsRequired()
 22564                        .HasMaxLength(32)
 22565                        .HasColumnType("TEXT");
 22566
 22567                    b.Property<string>("DashboardTheme")
 22568                        .HasMaxLength(32)
 22569                        .HasColumnType("TEXT");
 22570
 22571                    b.Property<bool>("EnableNextVideoInfoOverlay")
 22572                        .HasColumnType("INTEGER");
 22573
 22574                    b.Property<int?>("IndexBy")
 22575                        .HasColumnType("INTEGER");
 22576
 22577                    b.Property<Guid>("ItemId")
 22578                        .HasColumnType("TEXT");
 22579
 22580                    b.Property<int>("ScrollDirection")
 22581                        .HasColumnType("INTEGER");
 22582
 22583                    b.Property<bool>("ShowBackdrop")
 22584                        .HasColumnType("INTEGER");
 22585
 22586                    b.Property<bool>("ShowSidebar")
 22587                        .HasColumnType("INTEGER");
 22588
 22589                    b.Property<int>("SkipBackwardLength")
 22590                        .HasColumnType("INTEGER");
 22591
 22592                    b.Property<int>("SkipForwardLength")
 22593                        .HasColumnType("INTEGER");
 22594
 22595                    b.Property<string>("TvHome")
 22596                        .HasMaxLength(32)
 22597                        .HasColumnType("TEXT");
 22598
 22599                    b.Property<Guid>("UserId")
 22600                        .HasColumnType("TEXT");
 22601
 22602                    b.HasKey("Id");
 22603
 22604                    b.HasIndex("UserId", "ItemId", "Client")
 22605                        .IsUnique();
 22606
 22607                    b.ToTable("DisplayPreferences");
 22608
 22609                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22610                });
 611
 22612            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.HomeSection", b =>
 22613                {
 22614                    b.Property<int>("Id")
 22615                        .ValueGeneratedOnAdd()
 22616                        .HasColumnType("INTEGER");
 22617
 22618                    b.Property<int>("DisplayPreferencesId")
 22619                        .HasColumnType("INTEGER");
 22620
 22621                    b.Property<int>("Order")
 22622                        .HasColumnType("INTEGER");
 22623
 22624                    b.Property<int>("Type")
 22625                        .HasColumnType("INTEGER");
 22626
 22627                    b.HasKey("Id");
 22628
 22629                    b.HasIndex("DisplayPreferencesId");
 22630
 22631                    b.ToTable("HomeSection");
 22632
 22633                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22634                });
 635
 22636            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ImageInfo", b =>
 22637                {
 22638                    b.Property<int>("Id")
 22639                        .ValueGeneratedOnAdd()
 22640                        .HasColumnType("INTEGER");
 22641
 22642                    b.Property<DateTime>("LastModified")
 22643                        .HasColumnType("TEXT");
 22644
 22645                    b.Property<string>("Path")
 22646                        .IsRequired()
 22647                        .HasMaxLength(512)
 22648                        .HasColumnType("TEXT");
 22649
 22650                    b.Property<Guid?>("UserId")
 22651                        .HasColumnType("TEXT");
 22652
 22653                    b.HasKey("Id");
 22654
 22655                    b.HasIndex("UserId")
 22656                        .IsUnique();
 22657
 22658                    b.ToTable("ImageInfos");
 22659
 22660                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22661                });
 662
 22663            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemDisplayPreferences", b =>
 22664                {
 22665                    b.Property<int>("Id")
 22666                        .ValueGeneratedOnAdd()
 22667                        .HasColumnType("INTEGER");
 22668
 22669                    b.Property<string>("Client")
 22670                        .IsRequired()
 22671                        .HasMaxLength(32)
 22672                        .HasColumnType("TEXT");
 22673
 22674                    b.Property<int?>("IndexBy")
 22675                        .HasColumnType("INTEGER");
 22676
 22677                    b.Property<Guid>("ItemId")
 22678                        .HasColumnType("TEXT");
 22679
 22680                    b.Property<bool>("RememberIndexing")
 22681                        .HasColumnType("INTEGER");
 22682
 22683                    b.Property<bool>("RememberSorting")
 22684                        .HasColumnType("INTEGER");
 22685
 22686                    b.Property<string>("SortBy")
 22687                        .IsRequired()
 22688                        .HasMaxLength(64)
 22689                        .HasColumnType("TEXT");
 22690
 22691                    b.Property<int>("SortOrder")
 22692                        .HasColumnType("INTEGER");
 22693
 22694                    b.Property<Guid>("UserId")
 22695                        .HasColumnType("TEXT");
 22696
 22697                    b.Property<int>("ViewType")
 22698                        .HasColumnType("INTEGER");
 22699
 22700                    b.HasKey("Id");
 22701
 22702                    b.HasIndex("UserId");
 22703
 22704                    b.ToTable("ItemDisplayPreferences");
 22705
 22706                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22707                });
 708
 22709            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValue", b =>
 22710                {
 22711                    b.Property<Guid>("ItemValueId")
 22712                        .ValueGeneratedOnAdd()
 22713                        .HasColumnType("TEXT");
 22714
 22715                    b.Property<string>("CleanValue")
 22716                        .IsRequired()
 22717                        .HasColumnType("TEXT");
 22718
 22719                    b.Property<int>("Type")
 22720                        .HasColumnType("INTEGER");
 22721
 22722                    b.Property<string>("Value")
 22723                        .IsRequired()
 22724                        .HasColumnType("TEXT");
 22725
 22726                    b.HasKey("ItemValueId");
 22727
 22728                    b.HasIndex("Type", "CleanValue")
 22729                        .IsUnique();
 22730
 22731                    b.ToTable("ItemValues");
 22732
 22733                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22734                });
 735
 22736            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValueMap", b =>
 22737                {
 22738                    b.Property<Guid>("ItemValueId")
 22739                        .HasColumnType("TEXT");
 22740
 22741                    b.Property<Guid>("ItemId")
 22742                        .HasColumnType("TEXT");
 22743
 22744                    b.HasKey("ItemValueId", "ItemId");
 22745
 22746                    b.HasIndex("ItemId");
 22747
 22748                    b.ToTable("ItemValuesMap");
 22749
 22750                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22751                });
 752
 22753            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.KeyframeData", b =>
 22754                {
 22755                    b.Property<Guid>("ItemId")
 22756                        .HasColumnType("TEXT");
 22757
 22758                    b.PrimitiveCollection<string>("KeyframeTicks")
 22759                        .HasColumnType("TEXT");
 22760
 22761                    b.Property<long>("TotalDuration")
 22762                        .HasColumnType("INTEGER");
 22763
 22764                    b.HasKey("ItemId");
 22765
 22766                    b.ToTable("KeyframeData");
 22767
 22768                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22769                });
 770
 22771            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaSegment", b =>
 22772                {
 22773                    b.Property<Guid>("Id")
 22774                        .ValueGeneratedOnAdd()
 22775                        .HasColumnType("TEXT");
 22776
 22777                    b.Property<long>("EndTicks")
 22778                        .HasColumnType("INTEGER");
 22779
 22780                    b.Property<Guid>("ItemId")
 22781                        .HasColumnType("TEXT");
 22782
 22783                    b.Property<string>("SegmentProviderId")
 22784                        .IsRequired()
 22785                        .HasColumnType("TEXT");
 22786
 22787                    b.Property<long>("StartTicks")
 22788                        .HasColumnType("INTEGER");
 22789
 22790                    b.Property<int>("Type")
 22791                        .HasColumnType("INTEGER");
 22792
 22793                    b.HasKey("Id");
 22794
 22795                    b.ToTable("MediaSegments");
 22796
 22797                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22798                });
 799
 22800            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaStreamInfo", b =>
 22801                {
 22802                    b.Property<Guid>("ItemId")
 22803                        .HasColumnType("TEXT");
 22804
 22805                    b.Property<int>("StreamIndex")
 22806                        .HasColumnType("INTEGER");
 22807
 22808                    b.Property<string>("AspectRatio")
 22809                        .HasColumnType("TEXT");
 22810
 22811                    b.Property<float?>("AverageFrameRate")
 22812                        .HasColumnType("REAL");
 22813
 22814                    b.Property<int?>("BitDepth")
 22815                        .HasColumnType("INTEGER");
 22816
 22817                    b.Property<int?>("BitRate")
 22818                        .HasColumnType("INTEGER");
 22819
 22820                    b.Property<int?>("BlPresentFlag")
 22821                        .HasColumnType("INTEGER");
 22822
 22823                    b.Property<string>("ChannelLayout")
 22824                        .HasColumnType("TEXT");
 22825
 22826                    b.Property<int?>("Channels")
 22827                        .HasColumnType("INTEGER");
 22828
 22829                    b.Property<string>("Codec")
 22830                        .HasColumnType("TEXT");
 22831
 22832                    b.Property<string>("CodecTag")
 22833                        .HasColumnType("TEXT");
 22834
 22835                    b.Property<string>("CodecTimeBase")
 22836                        .HasColumnType("TEXT");
 22837
 22838                    b.Property<string>("ColorPrimaries")
 22839                        .HasColumnType("TEXT");
 22840
 22841                    b.Property<string>("ColorSpace")
 22842                        .HasColumnType("TEXT");
 22843
 22844                    b.Property<string>("ColorTransfer")
 22845                        .HasColumnType("TEXT");
 22846
 22847                    b.Property<string>("Comment")
 22848                        .HasColumnType("TEXT");
 22849
 22850                    b.Property<int?>("DvBlSignalCompatibilityId")
 22851                        .HasColumnType("INTEGER");
 22852
 22853                    b.Property<int?>("DvLevel")
 22854                        .HasColumnType("INTEGER");
 22855
 22856                    b.Property<int?>("DvProfile")
 22857                        .HasColumnType("INTEGER");
 22858
 22859                    b.Property<int?>("DvVersionMajor")
 22860                        .HasColumnType("INTEGER");
 22861
 22862                    b.Property<int?>("DvVersionMinor")
 22863                        .HasColumnType("INTEGER");
 22864
 22865                    b.Property<int?>("ElPresentFlag")
 22866                        .HasColumnType("INTEGER");
 22867
 22868                    b.Property<bool?>("Hdr10PlusPresentFlag")
 22869                        .HasColumnType("INTEGER");
 22870
 22871                    b.Property<int?>("Height")
 22872                        .HasColumnType("INTEGER");
 22873
 22874                    b.Property<bool?>("IsAnamorphic")
 22875                        .HasColumnType("INTEGER");
 22876
 22877                    b.Property<bool?>("IsAvc")
 22878                        .HasColumnType("INTEGER");
 22879
 22880                    b.Property<bool>("IsDefault")
 22881                        .HasColumnType("INTEGER");
 22882
 22883                    b.Property<bool>("IsExternal")
 22884                        .HasColumnType("INTEGER");
 22885
 22886                    b.Property<bool>("IsForced")
 22887                        .HasColumnType("INTEGER");
 22888
 22889                    b.Property<bool?>("IsHearingImpaired")
 22890                        .HasColumnType("INTEGER");
 22891
 22892                    b.Property<bool?>("IsInterlaced")
 22893                        .HasColumnType("INTEGER");
 22894
 22895                    b.Property<string>("KeyFrames")
 22896                        .HasColumnType("TEXT");
 22897
 22898                    b.Property<string>("Language")
 22899                        .HasColumnType("TEXT");
 22900
 22901                    b.Property<float?>("Level")
 22902                        .HasColumnType("REAL");
 22903
 22904                    b.Property<string>("NalLengthSize")
 22905                        .HasColumnType("TEXT");
 22906
 22907                    b.Property<string>("Path")
 22908                        .HasColumnType("TEXT");
 22909
 22910                    b.Property<string>("PixelFormat")
 22911                        .HasColumnType("TEXT");
 22912
 22913                    b.Property<string>("Profile")
 22914                        .HasColumnType("TEXT");
 22915
 22916                    b.Property<float?>("RealFrameRate")
 22917                        .HasColumnType("REAL");
 22918
 22919                    b.Property<int?>("RefFrames")
 22920                        .HasColumnType("INTEGER");
 22921
 22922                    b.Property<int?>("Rotation")
 22923                        .HasColumnType("INTEGER");
 22924
 22925                    b.Property<int?>("RpuPresentFlag")
 22926                        .HasColumnType("INTEGER");
 22927
 22928                    b.Property<int?>("SampleRate")
 22929                        .HasColumnType("INTEGER");
 22930
 22931                    b.Property<int>("StreamType")
 22932                        .HasColumnType("INTEGER");
 22933
 22934                    b.Property<string>("TimeBase")
 22935                        .HasColumnType("TEXT");
 22936
 22937                    b.Property<string>("Title")
 22938                        .HasColumnType("TEXT");
 22939
 22940                    b.Property<int?>("Width")
 22941                        .HasColumnType("INTEGER");
 22942
 22943                    b.HasKey("ItemId", "StreamIndex");
 22944
 22945                    b.HasIndex("StreamIndex");
 22946
 22947                    b.HasIndex("StreamType");
 22948
 22949                    b.HasIndex("StreamIndex", "StreamType");
 22950
 22951                    b.HasIndex("StreamIndex", "StreamType", "Language");
 22952
 22953                    b.ToTable("MediaStreamInfos");
 22954
 22955                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22956                });
 957
 22958            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.People", b =>
 22959                {
 22960                    b.Property<Guid>("Id")
 22961                        .ValueGeneratedOnAdd()
 22962                        .HasColumnType("TEXT");
 22963
 22964                    b.Property<string>("Name")
 22965                        .IsRequired()
 22966                        .HasColumnType("TEXT");
 22967
 22968                    b.Property<string>("PersonType")
 22969                        .HasColumnType("TEXT");
 22970
 22971                    b.HasKey("Id");
 22972
 22973                    b.HasIndex("Name");
 22974
 22975                    b.ToTable("Peoples");
 22976
 22977                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 22978                });
 979
 22980            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.PeopleBaseItemMap", b =>
 22981                {
 22982                    b.Property<Guid>("ItemId")
 22983                        .HasColumnType("TEXT");
 22984
 22985                    b.Property<Guid>("PeopleId")
 22986                        .HasColumnType("TEXT");
 22987
 22988                    b.Property<int?>("ListOrder")
 22989                        .HasColumnType("INTEGER");
 22990
 22991                    b.Property<string>("Role")
 22992                        .HasColumnType("TEXT");
 22993
 22994                    b.Property<int?>("SortOrder")
 22995                        .HasColumnType("INTEGER");
 22996
 22997                    b.HasKey("ItemId", "PeopleId");
 22998
 22999                    b.HasIndex("PeopleId");
 221000
 221001                    b.HasIndex("ItemId", "ListOrder");
 221002
 221003                    b.HasIndex("ItemId", "SortOrder");
 221004
 221005                    b.ToTable("PeopleBaseItemMap");
 221006
 221007                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221008                });
 1009
 221010            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Permission", b =>
 221011                {
 221012                    b.Property<int>("Id")
 221013                        .ValueGeneratedOnAdd()
 221014                        .HasColumnType("INTEGER");
 221015
 221016                    b.Property<int>("Kind")
 221017                        .HasColumnType("INTEGER");
 221018
 221019                    b.Property<Guid?>("Permission_Permissions_Guid")
 221020                        .HasColumnType("TEXT");
 221021
 221022                    b.Property<uint>("RowVersion")
 221023                        .IsConcurrencyToken()
 221024                        .HasColumnType("INTEGER");
 221025
 221026                    b.Property<Guid?>("UserId")
 221027                        .HasColumnType("TEXT");
 221028
 221029                    b.Property<bool>("Value")
 221030                        .HasColumnType("INTEGER");
 221031
 221032                    b.HasKey("Id");
 221033
 221034                    b.HasIndex("UserId", "Kind")
 221035                        .IsUnique()
 221036                        .HasFilter("[UserId] IS NOT NULL");
 221037
 221038                    b.ToTable("Permissions");
 221039
 221040                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221041                });
 1042
 221043            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Preference", b =>
 221044                {
 221045                    b.Property<int>("Id")
 221046                        .ValueGeneratedOnAdd()
 221047                        .HasColumnType("INTEGER");
 221048
 221049                    b.Property<int>("Kind")
 221050                        .HasColumnType("INTEGER");
 221051
 221052                    b.Property<Guid?>("Preference_Preferences_Guid")
 221053                        .HasColumnType("TEXT");
 221054
 221055                    b.Property<uint>("RowVersion")
 221056                        .IsConcurrencyToken()
 221057                        .HasColumnType("INTEGER");
 221058
 221059                    b.Property<Guid?>("UserId")
 221060                        .HasColumnType("TEXT");
 221061
 221062                    b.Property<string>("Value")
 221063                        .IsRequired()
 221064                        .HasMaxLength(65535)
 221065                        .HasColumnType("TEXT");
 221066
 221067                    b.HasKey("Id");
 221068
 221069                    b.HasIndex("UserId", "Kind")
 221070                        .IsUnique()
 221071                        .HasFilter("[UserId] IS NOT NULL");
 221072
 221073                    b.ToTable("Preferences");
 221074
 221075                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221076                });
 1077
 221078            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.ApiKey", b =>
 221079                {
 221080                    b.Property<int>("Id")
 221081                        .ValueGeneratedOnAdd()
 221082                        .HasColumnType("INTEGER");
 221083
 221084                    b.Property<string>("AccessToken")
 221085                        .IsRequired()
 221086                        .HasColumnType("TEXT");
 221087
 221088                    b.Property<DateTime>("DateCreated")
 221089                        .HasColumnType("TEXT");
 221090
 221091                    b.Property<DateTime>("DateLastActivity")
 221092                        .HasColumnType("TEXT");
 221093
 221094                    b.Property<string>("Name")
 221095                        .IsRequired()
 221096                        .HasMaxLength(64)
 221097                        .HasColumnType("TEXT");
 221098
 221099                    b.HasKey("Id");
 221100
 221101                    b.HasIndex("AccessToken")
 221102                        .IsUnique();
 221103
 221104                    b.ToTable("ApiKeys");
 221105
 221106                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221107                });
 1108
 221109            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.Device", b =>
 221110                {
 221111                    b.Property<int>("Id")
 221112                        .ValueGeneratedOnAdd()
 221113                        .HasColumnType("INTEGER");
 221114
 221115                    b.Property<string>("AccessToken")
 221116                        .IsRequired()
 221117                        .HasColumnType("TEXT");
 221118
 221119                    b.Property<string>("AppName")
 221120                        .IsRequired()
 221121                        .HasMaxLength(64)
 221122                        .HasColumnType("TEXT");
 221123
 221124                    b.Property<string>("AppVersion")
 221125                        .IsRequired()
 221126                        .HasMaxLength(32)
 221127                        .HasColumnType("TEXT");
 221128
 221129                    b.Property<DateTime>("DateCreated")
 221130                        .HasColumnType("TEXT");
 221131
 221132                    b.Property<DateTime>("DateLastActivity")
 221133                        .HasColumnType("TEXT");
 221134
 221135                    b.Property<DateTime>("DateModified")
 221136                        .HasColumnType("TEXT");
 221137
 221138                    b.Property<string>("DeviceId")
 221139                        .IsRequired()
 221140                        .HasMaxLength(256)
 221141                        .HasColumnType("TEXT");
 221142
 221143                    b.Property<string>("DeviceName")
 221144                        .IsRequired()
 221145                        .HasMaxLength(64)
 221146                        .HasColumnType("TEXT");
 221147
 221148                    b.Property<bool>("IsActive")
 221149                        .HasColumnType("INTEGER");
 221150
 221151                    b.Property<Guid>("UserId")
 221152                        .HasColumnType("TEXT");
 221153
 221154                    b.HasKey("Id");
 221155
 221156                    b.HasIndex("DeviceId");
 221157
 221158                    b.HasIndex("AccessToken", "DateLastActivity");
 221159
 221160                    b.HasIndex("DeviceId", "DateLastActivity");
 221161
 221162                    b.HasIndex("UserId", "DeviceId");
 221163
 221164                    b.ToTable("Devices");
 221165
 221166                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221167                });
 1168
 221169            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.DeviceOptions", b =>
 221170                {
 221171                    b.Property<int>("Id")
 221172                        .ValueGeneratedOnAdd()
 221173                        .HasColumnType("INTEGER");
 221174
 221175                    b.Property<string>("CustomName")
 221176                        .HasColumnType("TEXT");
 221177
 221178                    b.Property<string>("DeviceId")
 221179                        .IsRequired()
 221180                        .HasColumnType("TEXT");
 221181
 221182                    b.HasKey("Id");
 221183
 221184                    b.HasIndex("DeviceId")
 221185                        .IsUnique();
 221186
 221187                    b.ToTable("DeviceOptions");
 221188
 221189                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221190                });
 1191
 221192            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.TrickplayInfo", b =>
 221193                {
 221194                    b.Property<Guid>("ItemId")
 221195                        .HasColumnType("TEXT");
 221196
 221197                    b.Property<int>("Width")
 221198                        .HasColumnType("INTEGER");
 221199
 221200                    b.Property<int>("Bandwidth")
 221201                        .HasColumnType("INTEGER");
 221202
 221203                    b.Property<int>("Height")
 221204                        .HasColumnType("INTEGER");
 221205
 221206                    b.Property<int>("Interval")
 221207                        .HasColumnType("INTEGER");
 221208
 221209                    b.Property<int>("ThumbnailCount")
 221210                        .HasColumnType("INTEGER");
 221211
 221212                    b.Property<int>("TileHeight")
 221213                        .HasColumnType("INTEGER");
 221214
 221215                    b.Property<int>("TileWidth")
 221216                        .HasColumnType("INTEGER");
 221217
 221218                    b.HasKey("ItemId", "Width");
 221219
 221220                    b.ToTable("TrickplayInfos");
 221221
 221222                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221223                });
 1224
 221225            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.User", b =>
 221226                {
 221227                    b.Property<Guid>("Id")
 221228                        .ValueGeneratedOnAdd()
 221229                        .HasColumnType("TEXT");
 221230
 221231                    b.Property<string>("AudioLanguagePreference")
 221232                        .HasMaxLength(255)
 221233                        .HasColumnType("TEXT");
 221234
 221235                    b.Property<string>("AuthenticationProviderId")
 221236                        .IsRequired()
 221237                        .HasMaxLength(255)
 221238                        .HasColumnType("TEXT");
 221239
 221240                    b.Property<string>("CastReceiverId")
 221241                        .HasMaxLength(32)
 221242                        .HasColumnType("TEXT");
 221243
 221244                    b.Property<bool>("DisplayCollectionsView")
 221245                        .HasColumnType("INTEGER");
 221246
 221247                    b.Property<bool>("DisplayMissingEpisodes")
 221248                        .HasColumnType("INTEGER");
 221249
 221250                    b.Property<bool>("EnableAutoLogin")
 221251                        .HasColumnType("INTEGER");
 221252
 221253                    b.Property<bool>("EnableLocalPassword")
 221254                        .HasColumnType("INTEGER");
 221255
 221256                    b.Property<bool>("EnableNextEpisodeAutoPlay")
 221257                        .HasColumnType("INTEGER");
 221258
 221259                    b.Property<bool>("EnableUserPreferenceAccess")
 221260                        .HasColumnType("INTEGER");
 221261
 221262                    b.Property<bool>("HidePlayedInLatest")
 221263                        .HasColumnType("INTEGER");
 221264
 221265                    b.Property<long>("InternalId")
 221266                        .HasColumnType("INTEGER");
 221267
 221268                    b.Property<int>("InvalidLoginAttemptCount")
 221269                        .HasColumnType("INTEGER");
 221270
 221271                    b.Property<DateTime?>("LastActivityDate")
 221272                        .HasColumnType("TEXT");
 221273
 221274                    b.Property<DateTime?>("LastLoginDate")
 221275                        .HasColumnType("TEXT");
 221276
 221277                    b.Property<int?>("LoginAttemptsBeforeLockout")
 221278                        .HasColumnType("INTEGER");
 221279
 221280                    b.Property<int>("MaxActiveSessions")
 221281                        .HasColumnType("INTEGER");
 221282
 221283                    b.Property<int?>("MaxParentalRatingScore")
 221284                        .HasColumnType("INTEGER");
 221285
 221286                    b.Property<int?>("MaxParentalRatingSubScore")
 221287                        .HasColumnType("INTEGER");
 221288
 221289                    b.Property<bool>("MustUpdatePassword")
 221290                        .HasColumnType("INTEGER");
 221291
 221292                    b.Property<string>("Password")
 221293                        .HasMaxLength(65535)
 221294                        .HasColumnType("TEXT");
 221295
 221296                    b.Property<string>("PasswordResetProviderId")
 221297                        .IsRequired()
 221298                        .HasMaxLength(255)
 221299                        .HasColumnType("TEXT");
 221300
 221301                    b.Property<bool>("PlayDefaultAudioTrack")
 221302                        .HasColumnType("INTEGER");
 221303
 221304                    b.Property<bool>("RememberAudioSelections")
 221305                        .HasColumnType("INTEGER");
 221306
 221307                    b.Property<bool>("RememberSubtitleSelections")
 221308                        .HasColumnType("INTEGER");
 221309
 221310                    b.Property<int?>("RemoteClientBitrateLimit")
 221311                        .HasColumnType("INTEGER");
 221312
 221313                    b.Property<uint>("RowVersion")
 221314                        .IsConcurrencyToken()
 221315                        .HasColumnType("INTEGER");
 221316
 221317                    b.Property<string>("SubtitleLanguagePreference")
 221318                        .HasMaxLength(255)
 221319                        .HasColumnType("TEXT");
 221320
 221321                    b.Property<int>("SubtitleMode")
 221322                        .HasColumnType("INTEGER");
 221323
 221324                    b.Property<int>("SyncPlayAccess")
 221325                        .HasColumnType("INTEGER");
 221326
 221327                    b.Property<string>("Username")
 221328                        .IsRequired()
 221329                        .HasMaxLength(255)
 221330                        .HasColumnType("TEXT");
 221331
 221332                    b.HasKey("Id");
 221333
 221334                    b.HasIndex("Username")
 221335                        .IsUnique();
 221336
 221337                    b.ToTable("Users");
 221338
 221339                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221340                });
 1341
 221342            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.UserData", b =>
 221343                {
 221344                    b.Property<Guid>("ItemId")
 221345                        .HasColumnType("TEXT");
 221346
 221347                    b.Property<Guid>("UserId")
 221348                        .HasColumnType("TEXT");
 221349
 221350                    b.Property<string>("CustomDataKey")
 221351                        .HasColumnType("TEXT");
 221352
 221353                    b.Property<int?>("AudioStreamIndex")
 221354                        .HasColumnType("INTEGER");
 221355
 221356                    b.Property<bool>("IsFavorite")
 221357                        .HasColumnType("INTEGER");
 221358
 221359                    b.Property<DateTime?>("LastPlayedDate")
 221360                        .HasColumnType("TEXT");
 221361
 221362                    b.Property<bool?>("Likes")
 221363                        .HasColumnType("INTEGER");
 221364
 221365                    b.Property<int>("PlayCount")
 221366                        .HasColumnType("INTEGER");
 221367
 221368                    b.Property<long>("PlaybackPositionTicks")
 221369                        .HasColumnType("INTEGER");
 221370
 221371                    b.Property<bool>("Played")
 221372                        .HasColumnType("INTEGER");
 221373
 221374                    b.Property<double?>("Rating")
 221375                        .HasColumnType("REAL");
 221376
 221377                    b.Property<int?>("SubtitleStreamIndex")
 221378                        .HasColumnType("INTEGER");
 221379
 221380                    b.HasKey("ItemId", "UserId", "CustomDataKey");
 221381
 221382                    b.HasIndex("UserId");
 221383
 221384                    b.HasIndex("ItemId", "UserId", "IsFavorite");
 221385
 221386                    b.HasIndex("ItemId", "UserId", "LastPlayedDate");
 221387
 221388                    b.HasIndex("ItemId", "UserId", "PlaybackPositionTicks");
 221389
 221390                    b.HasIndex("ItemId", "UserId", "Played");
 221391
 221392                    b.ToTable("UserData");
 221393
 221394                    b.HasAnnotation("Sqlite:UseSqlReturningClause", false);
 221395                });
 1396
 221397            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AccessSchedule", b =>
 221398                {
 221399                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 221400                        .WithMany("AccessSchedules")
 221401                        .HasForeignKey("UserId")
 221402                        .OnDelete(DeleteBehavior.Cascade)
 221403                        .IsRequired();
 221404                });
 1405
 221406            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AncestorId", b =>
 221407                {
 221408                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221409                        .WithMany("Parents")
 221410                        .HasForeignKey("ItemId")
 221411                        .OnDelete(DeleteBehavior.Cascade)
 221412                        .IsRequired();
 221413
 221414                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "ParentItem")
 221415                        .WithMany("Children")
 221416                        .HasForeignKey("ParentItemId")
 221417                        .OnDelete(DeleteBehavior.Cascade)
 221418                        .IsRequired();
 221419
 221420                    b.Navigation("Item");
 221421
 221422                    b.Navigation("ParentItem");
 221423                });
 1424
 221425            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.AttachmentStreamInfo", b =>
 221426                {
 221427                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221428                        .WithMany()
 221429                        .HasForeignKey("ItemId")
 221430                        .OnDelete(DeleteBehavior.Cascade)
 221431                        .IsRequired();
 221432
 221433                    b.Navigation("Item");
 221434                });
 1435
 221436            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemImageInfo", b =>
 221437                {
 221438                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221439                        .WithMany("Images")
 221440                        .HasForeignKey("ItemId")
 221441                        .OnDelete(DeleteBehavior.Cascade)
 221442                        .IsRequired();
 221443
 221444                    b.Navigation("Item");
 221445                });
 1446
 221447            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemMetadataField", b =>
 221448                {
 221449                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221450                        .WithMany("LockedFields")
 221451                        .HasForeignKey("ItemId")
 221452                        .OnDelete(DeleteBehavior.Cascade)
 221453                        .IsRequired();
 221454
 221455                    b.Navigation("Item");
 221456                });
 1457
 221458            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemProvider", b =>
 221459                {
 221460                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221461                        .WithMany("Provider")
 221462                        .HasForeignKey("ItemId")
 221463                        .OnDelete(DeleteBehavior.Cascade)
 221464                        .IsRequired();
 221465
 221466                    b.Navigation("Item");
 221467                });
 1468
 221469            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemTrailerType", b =>
 221470                {
 221471                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221472                        .WithMany("TrailerTypes")
 221473                        .HasForeignKey("ItemId")
 221474                        .OnDelete(DeleteBehavior.Cascade)
 221475                        .IsRequired();
 221476
 221477                    b.Navigation("Item");
 221478                });
 1479
 221480            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Chapter", b =>
 221481                {
 221482                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221483                        .WithMany("Chapters")
 221484                        .HasForeignKey("ItemId")
 221485                        .OnDelete(DeleteBehavior.Cascade)
 221486                        .IsRequired();
 221487
 221488                    b.Navigation("Item");
 221489                });
 1490
 221491            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 221492                {
 221493                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 221494                        .WithMany("DisplayPreferences")
 221495                        .HasForeignKey("UserId")
 221496                        .OnDelete(DeleteBehavior.Cascade)
 221497                        .IsRequired();
 221498                });
 1499
 221500            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.HomeSection", b =>
 221501                {
 221502                    b.HasOne("Jellyfin.Database.Implementations.Entities.DisplayPreferences", null)
 221503                        .WithMany("HomeSections")
 221504                        .HasForeignKey("DisplayPreferencesId")
 221505                        .OnDelete(DeleteBehavior.Cascade)
 221506                        .IsRequired();
 221507                });
 1508
 221509            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ImageInfo", b =>
 221510                {
 221511                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 221512                        .WithOne("ProfileImage")
 221513                        .HasForeignKey("Jellyfin.Database.Implementations.Entities.ImageInfo", "UserId")
 221514                        .OnDelete(DeleteBehavior.Cascade);
 221515                });
 1516
 221517            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemDisplayPreferences", b =>
 221518                {
 221519                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 221520                        .WithMany("ItemDisplayPreferences")
 221521                        .HasForeignKey("UserId")
 221522                        .OnDelete(DeleteBehavior.Cascade)
 221523                        .IsRequired();
 221524                });
 1525
 221526            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValueMap", b =>
 221527                {
 221528                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221529                        .WithMany("ItemValues")
 221530                        .HasForeignKey("ItemId")
 221531                        .OnDelete(DeleteBehavior.Cascade)
 221532                        .IsRequired();
 221533
 221534                    b.HasOne("Jellyfin.Database.Implementations.Entities.ItemValue", "ItemValue")
 221535                        .WithMany("BaseItemsMap")
 221536                        .HasForeignKey("ItemValueId")
 221537                        .OnDelete(DeleteBehavior.Cascade)
 221538                        .IsRequired();
 221539
 221540                    b.Navigation("Item");
 221541
 221542                    b.Navigation("ItemValue");
 221543                });
 1544
 221545            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.KeyframeData", b =>
 221546                {
 221547                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221548                        .WithMany()
 221549                        .HasForeignKey("ItemId")
 221550                        .OnDelete(DeleteBehavior.Cascade)
 221551                        .IsRequired();
 221552
 221553                    b.Navigation("Item");
 221554                });
 1555
 221556            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.MediaStreamInfo", b =>
 221557                {
 221558                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221559                        .WithMany("MediaStreams")
 221560                        .HasForeignKey("ItemId")
 221561                        .OnDelete(DeleteBehavior.Cascade)
 221562                        .IsRequired();
 221563
 221564                    b.Navigation("Item");
 221565                });
 1566
 221567            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.PeopleBaseItemMap", b =>
 221568                {
 221569                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221570                        .WithMany("Peoples")
 221571                        .HasForeignKey("ItemId")
 221572                        .OnDelete(DeleteBehavior.Cascade)
 221573                        .IsRequired();
 221574
 221575                    b.HasOne("Jellyfin.Database.Implementations.Entities.People", "People")
 221576                        .WithMany("BaseItems")
 221577                        .HasForeignKey("PeopleId")
 221578                        .OnDelete(DeleteBehavior.Cascade)
 221579                        .IsRequired();
 221580
 221581                    b.Navigation("Item");
 221582
 221583                    b.Navigation("People");
 221584                });
 1585
 221586            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Permission", b =>
 221587                {
 221588                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 221589                        .WithMany("Permissions")
 221590                        .HasForeignKey("UserId")
 221591                        .OnDelete(DeleteBehavior.Cascade);
 221592                });
 1593
 221594            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Preference", b =>
 221595                {
 221596                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", null)
 221597                        .WithMany("Preferences")
 221598                        .HasForeignKey("UserId")
 221599                        .OnDelete(DeleteBehavior.Cascade);
 221600                });
 1601
 221602            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.Security.Device", b =>
 221603                {
 221604                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", "User")
 221605                        .WithMany()
 221606                        .HasForeignKey("UserId")
 221607                        .OnDelete(DeleteBehavior.Cascade)
 221608                        .IsRequired();
 221609
 221610                    b.Navigation("User");
 221611                });
 1612
 221613            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.UserData", b =>
 221614                {
 221615                    b.HasOne("Jellyfin.Database.Implementations.Entities.BaseItemEntity", "Item")
 221616                        .WithMany("UserData")
 221617                        .HasForeignKey("ItemId")
 221618                        .OnDelete(DeleteBehavior.Cascade)
 221619                        .IsRequired();
 221620
 221621                    b.HasOne("Jellyfin.Database.Implementations.Entities.User", "User")
 221622                        .WithMany()
 221623                        .HasForeignKey("UserId")
 221624                        .OnDelete(DeleteBehavior.Cascade)
 221625                        .IsRequired();
 221626
 221627                    b.Navigation("Item");
 221628
 221629                    b.Navigation("User");
 221630                });
 1631
 221632            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.BaseItemEntity", b =>
 221633                {
 221634                    b.Navigation("Chapters");
 221635
 221636                    b.Navigation("Children");
 221637
 221638                    b.Navigation("Images");
 221639
 221640                    b.Navigation("ItemValues");
 221641
 221642                    b.Navigation("LockedFields");
 221643
 221644                    b.Navigation("MediaStreams");
 221645
 221646                    b.Navigation("Parents");
 221647
 221648                    b.Navigation("Peoples");
 221649
 221650                    b.Navigation("Provider");
 221651
 221652                    b.Navigation("TrailerTypes");
 221653
 221654                    b.Navigation("UserData");
 221655                });
 1656
 221657            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.DisplayPreferences", b =>
 221658                {
 221659                    b.Navigation("HomeSections");
 221660                });
 1661
 221662            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.ItemValue", b =>
 221663                {
 221664                    b.Navigation("BaseItemsMap");
 221665                });
 1666
 221667            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.People", b =>
 221668                {
 221669                    b.Navigation("BaseItems");
 221670                });
 1671
 221672            modelBuilder.Entity("Jellyfin.Database.Implementations.Entities.User", b =>
 221673                {
 221674                    b.Navigation("AccessSchedules");
 221675
 221676                    b.Navigation("DisplayPreferences");
 221677
 221678                    b.Navigation("ItemDisplayPreferences");
 221679
 221680                    b.Navigation("Permissions");
 221681
 221682                    b.Navigation("Preferences");
 221683
 221684                    b.Navigation("ProfileImage");
 221685                });
 1686#pragma warning restore 612, 618
 221687        }
 1688    }
 1689}