telans пре 5 година
родитељ
комит
247f9c61e6
100 измењених фајлова са 632 додато и 0 уклоњено
  1. 1 0
      DvdLib/Ifo/Cell.cs
  2. 2 0
      DvdLib/Ifo/Chapter.cs
  3. 1 0
      DvdLib/Ifo/Dvd.cs
  4. 4 0
      DvdLib/Ifo/ProgramChain.cs
  5. 4 0
      DvdLib/Ifo/Title.cs
  6. 1 0
      Emby.Dlna/ContentDirectory/ControlHandler.cs
  7. 3 0
      Emby.Dlna/Didl/DidlBuilder.cs
  8. 3 0
      Emby.Dlna/DlnaManager.cs
  9. 1 0
      Emby.Dlna/Eventing/EventManager.cs
  10. 3 0
      Emby.Dlna/Eventing/EventSubscription.cs
  11. 2 0
      Emby.Dlna/Main/DlnaEntryPoint.cs
  12. 2 0
      Emby.Dlna/PlayTo/Device.cs
  13. 5 0
      Emby.Dlna/PlayTo/PlayToController.cs
  14. 1 0
      Emby.Dlna/PlayTo/PlayToManager.cs
  15. 1 0
      Emby.Dlna/PlayTo/PlaybackStoppedEventArgs.cs
  16. 2 0
      Emby.Dlna/PlayTo/uBaseObject.cs
  17. 5 0
      Emby.Dlna/Server/DescriptionXmlBuilder.cs
  18. 4 0
      Emby.Dlna/Service/BaseControlHandler.cs
  19. 1 0
      Emby.Dlna/Service/ServiceXmlBuilder.cs
  20. 1 0
      Emby.Naming/AudioBook/AudioBookFilePathParser.cs
  21. 115 0
      Emby.Server.Implementations/Data/SqliteItemRepository.cs
  22. 3 0
      Emby.Server.Implementations/Data/SqliteUserDataRepository.cs
  23. 1 0
      Emby.Server.Implementations/Devices/DeviceManager.cs
  24. 11 0
      Emby.Server.Implementations/Dto/DtoService.cs
  25. 1 0
      Emby.Server.Implementations/HttpServer/HttpListenerHost.cs
  26. 7 0
      Emby.Server.Implementations/HttpServer/RangeRequestWriter.cs
  27. 1 0
      Emby.Server.Implementations/HttpServer/Security/AuthService.cs
  28. 2 0
      Emby.Server.Implementations/HttpServer/Security/AuthorizationContext.cs
  29. 2 0
      Emby.Server.Implementations/IO/ManagedFileSystem.cs
  30. 2 0
      Emby.Server.Implementations/Library/ExclusiveLiveStream.cs
  31. 2 0
      Emby.Server.Implementations/Library/LibraryManager.cs
  32. 5 0
      Emby.Server.Implementations/Library/MediaSourceManager.cs
  33. 2 0
      Emby.Server.Implementations/Library/Resolvers/SpecialFolderResolver.cs
  34. 1 0
      Emby.Server.Implementations/Library/Resolvers/TV/EpisodeResolver.cs
  35. 1 0
      Emby.Server.Implementations/Library/SearchEngine.cs
  36. 118 0
      Emby.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs
  37. 1 0
      Emby.Server.Implementations/LiveTv/Listings/XmlTvListingsProvider.cs
  38. 12 0
      Emby.Server.Implementations/LiveTv/LiveTvManager.cs
  39. 19 0
      Emby.Server.Implementations/LiveTv/TunerHosts/HdHomerun/HdHomerunHost.cs
  40. 3 0
      Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs
  41. 1 0
      Emby.Server.Implementations/Playlists/PlaylistManager.cs
  42. 5 0
      Emby.Server.Implementations/ScheduledTasks/ScheduledTaskWorker.cs
  43. 1 0
      Emby.Server.Implementations/Services/ServiceMethod.cs
  44. 3 0
      Emby.Server.Implementations/Services/ServicePath.cs
  45. 2 0
      Emby.Server.Implementations/Services/StringMapTypeDeserializer.cs
  46. 34 0
      Emby.Server.Implementations/Services/SwaggerService.cs
  47. 1 0
      Emby.Server.Implementations/Session/SessionWebSocketListener.cs
  48. 1 0
      Emby.Server.Implementations/Sorting/PremiereDateComparer.cs
  49. 1 0
      Emby.Server.Implementations/TV/TVSeriesManager.cs
  50. 3 0
      Jellyfin.Data/Entities/Artwork.cs
  51. 1 0
      Jellyfin.Data/Entities/BookMetadata.cs
  52. 5 0
      Jellyfin.Data/Entities/Chapter.cs
  53. 2 0
      Jellyfin.Data/Entities/Collection.cs
  54. 1 0
      Jellyfin.Data/Entities/CollectionItem.cs
  55. 1 0
      Jellyfin.Data/Entities/Company.cs
  56. 4 0
      Jellyfin.Data/Entities/CompanyMetadata.cs
  57. 1 0
      Jellyfin.Data/Entities/Episode.cs
  58. 3 0
      Jellyfin.Data/Entities/EpisodeMetadata.cs
  59. 2 0
      Jellyfin.Data/Entities/Genre.cs
  60. 2 0
      Jellyfin.Data/Entities/Library.cs
  61. 3 0
      Jellyfin.Data/Entities/LibraryItem.cs
  62. 3 0
      Jellyfin.Data/Entities/LibraryRoot.cs
  63. 3 0
      Jellyfin.Data/Entities/MediaFile.cs
  64. 2 0
      Jellyfin.Data/Entities/MediaFileStream.cs
  65. 8 0
      Jellyfin.Data/Entities/Metadata.cs
  66. 2 0
      Jellyfin.Data/Entities/MetadataProvider.cs
  67. 2 0
      Jellyfin.Data/Entities/MetadataProviderId.cs
  68. 4 0
      Jellyfin.Data/Entities/MovieMetadata.cs
  69. 3 0
      Jellyfin.Data/Entities/MusicAlbumMetadata.cs
  70. 6 0
      Jellyfin.Data/Entities/Person.cs
  71. 3 0
      Jellyfin.Data/Entities/PersonRole.cs
  72. 3 0
      Jellyfin.Data/Entities/Rating.cs
  73. 4 0
      Jellyfin.Data/Entities/RatingSource.cs
  74. 2 0
      Jellyfin.Data/Entities/Release.cs
  75. 1 0
      Jellyfin.Data/Entities/Season.cs
  76. 1 0
      Jellyfin.Data/Entities/SeasonMetadata.cs
  77. 3 0
      Jellyfin.Data/Entities/Series.cs
  78. 4 0
      Jellyfin.Data/Entities/SeriesMetadata.cs
  79. 1 0
      Jellyfin.Data/Entities/Track.cs
  80. 39 0
      Jellyfin.Server.Implementations/JellyfinDb.cs
  81. 1 0
      MediaBrowser.Api/EnvironmentService.cs
  82. 6 0
      MediaBrowser.Api/FilterService.cs
  83. 1 0
      MediaBrowser.Api/IHasDtoOptions.cs
  84. 11 0
      MediaBrowser.Api/Library/LibraryService.cs
  85. 15 0
      MediaBrowser.Api/LiveTv/LiveTvService.cs
  86. 4 0
      MediaBrowser.Api/Playback/BaseStreamingService.cs
  87. 1 0
      MediaBrowser.Api/Playback/Hls/BaseHlsService.cs
  88. 2 0
      MediaBrowser.Api/Playback/Hls/DynamicHlsService.cs
  89. 2 0
      MediaBrowser.Api/Playback/MediaInfoService.cs
  90. 6 0
      MediaBrowser.Api/Playback/Progressive/BaseProgressiveStreamingService.cs
  91. 2 0
      MediaBrowser.Api/Playback/Progressive/ProgressiveStreamWriter.cs
  92. 4 0
      MediaBrowser.Api/Playback/StreamRequest.cs
  93. 20 0
      MediaBrowser.Api/Playback/UniversalAudioService.cs
  94. 9 0
      MediaBrowser.Api/PluginService.cs
  95. 4 0
      MediaBrowser.Api/SimilarItemsHelper.cs
  96. 2 0
      MediaBrowser.Api/Subtitles/SubtitleService.cs
  97. 5 0
      MediaBrowser.Api/SuggestionsService.cs
  98. 8 0
      MediaBrowser.Api/TranscodingJob.cs
  99. 1 0
      MediaBrowser.Api/TvShowsService.cs
  100. 1 0
      MediaBrowser.Api/UserLibrary/BaseItemsByNameService.cs

+ 1 - 0
DvdLib/Ifo/Cell.cs

@@ -7,6 +7,7 @@ namespace DvdLib.Ifo
     public class Cell
     {
         public CellPlaybackInfo PlaybackInfo { get; private set; }
+
         public CellPositionInfo PositionInfo { get; private set; }
 
         internal void ParsePlayback(BinaryReader br)

+ 2 - 0
DvdLib/Ifo/Chapter.cs

@@ -5,7 +5,9 @@ namespace DvdLib.Ifo
     public class Chapter
     {
         public ushort ProgramChainNumber { get; private set; }
+
         public ushort ProgramNumber { get; private set; }
+
         public uint ChapterNumber { get; private set; }
 
         public Chapter(ushort pgcNum, ushort programNum, uint chapterNum)

+ 1 - 0
DvdLib/Ifo/Dvd.cs

@@ -125,6 +125,7 @@ namespace DvdLib.Ifo
                             if (titleNum + 1 < numTitles && vtsFs.Position == (baseAddr + offsets[titleNum + 1])) break;
                             chapNum++;
                         }
+
                         while (vtsFs.Position < (baseAddr + endaddr));
                     }
 

+ 4 - 0
DvdLib/Ifo/ProgramChain.cs

@@ -22,7 +22,9 @@ namespace DvdLib.Ifo
         public readonly List<Cell> Cells;
 
         public DvdTime PlaybackTime { get; private set; }
+
         public UserOperation ProhibitedUserOperations { get; private set; }
+
         public byte[] AudioStreamControl { get; private set; } // 8*2 entries
         public byte[] SubpictureStreamControl { get; private set; } // 32*4 entries
 
@@ -33,9 +35,11 @@ namespace DvdLib.Ifo
         private ushort _goupProgramNumber;
 
         public ProgramPlaybackMode PlaybackMode { get; private set; }
+
         public uint ProgramCount { get; private set; }
 
         public byte StillTime { get; private set; }
+
         public byte[] Palette { get; private set; } // 16*4 entries
 
         private ushort _commandTableOffset;

+ 4 - 0
DvdLib/Ifo/Title.cs

@@ -8,8 +8,11 @@ namespace DvdLib.Ifo
     public class Title
     {
         public uint TitleNumber { get; private set; }
+
         public uint AngleCount { get; private set; }
+
         public ushort ChapterCount { get; private set; }
+
         public byte VideoTitleSetNumber { get; private set; }
 
         private ushort _parentalManagementMask;
@@ -17,6 +20,7 @@ namespace DvdLib.Ifo
         private uint _vtsStartSector; // relative to start of entire disk
 
         public ProgramChain EntryProgramChain { get; private set; }
+
         public readonly List<ProgramChain> ProgramChains;
 
         public readonly List<Chapter> Chapters;

+ 1 - 0
Emby.Dlna/ContentDirectory/ControlHandler.cs

@@ -1357,6 +1357,7 @@ namespace Emby.Dlna.ContentDirectory
     internal class ServerItem
     {
         public BaseItem Item { get; set; }
+
         public StubType? StubType { get; set; }
 
         public ServerItem(BaseItem item)

+ 3 - 0
Emby.Dlna/Didl/DidlBuilder.cs

@@ -765,6 +765,7 @@ namespace Emby.Dlna.Didl
                 {
                     AddValue(writer, "dc", "rating", item.OfficialRating, NS_DC);
                 }
+
                 if (filter.Contains("upnp:rating"))
                 {
                     AddValue(writer, "upnp", "rating", item.OfficialRating, NS_UPNP);
@@ -1052,10 +1053,12 @@ namespace Emby.Dlna.Didl
             {
                 return GetImageInfo(item, ImageType.Primary);
             }
+
             if (item.HasImage(ImageType.Thumb))
             {
                 return GetImageInfo(item, ImageType.Thumb);
             }
+
             if (item.HasImage(ImageType.Backdrop))
             {
                 if (item is Channel)

+ 3 - 0
Emby.Dlna/DlnaManager.cs

@@ -438,6 +438,7 @@ namespace Emby.Dlna
             {
                 throw new ArgumentException("Profile is missing Id");
             }
+
             if (string.IsNullOrEmpty(profile.Name))
             {
                 throw new ArgumentException("Profile is missing Name");
@@ -463,6 +464,7 @@ namespace Emby.Dlna
             {
                 _profiles[path] = new Tuple<InternalProfileInfo, DeviceProfile>(GetInternalProfileInfo(_fileSystem.GetFileInfo(path), type), profile);
             }
+
             SerializeToXml(profile, path);
         }
 
@@ -492,6 +494,7 @@ namespace Emby.Dlna
         class InternalProfileInfo
         {
             internal DeviceProfileInfo Info { get; set; }
+
             internal string Path { get; set; }
         }
 

+ 1 - 0
Emby.Dlna/Eventing/EventManager.cs

@@ -150,6 +150,7 @@ namespace Emby.Dlna.Eventing
                 builder.Append("</" + key + ">");
                 builder.Append("</e:property>");
             }
+
             builder.Append("</e:propertyset>");
 
             var options = new HttpRequestOptions

+ 3 - 0
Emby.Dlna/Eventing/EventSubscription.cs

@@ -7,10 +7,13 @@ namespace Emby.Dlna.Eventing
     public class EventSubscription
     {
         public string Id { get; set; }
+
         public string CallbackUrl { get; set; }
+
         public string NotificationType { get; set; }
 
         public DateTime SubscriptionTime { get; set; }
+
         public int TimeoutSeconds { get; set; }
 
         public long TriggerCount { get; set; }

+ 2 - 0
Emby.Dlna/Main/DlnaEntryPoint.cs

@@ -320,6 +320,7 @@ namespace Emby.Dlna.Main
             {
                 guid = text.GetMD5();
             }
+
             return guid.ToString("N", CultureInfo.InvariantCulture);
         }
 
@@ -388,6 +389,7 @@ namespace Emby.Dlna.Main
                     {
                         _logger.LogError(ex, "Error disposing PlayTo manager");
                     }
+
                     _manager = null;
                 }
             }

+ 2 - 0
Emby.Dlna/PlayTo/Device.cs

@@ -37,6 +37,7 @@ namespace Emby.Dlna.PlayTo
                 RefreshVolumeIfNeeded().GetAwaiter().GetResult();
                 return _volume;
             }
+
             set => _volume = value;
         }
 
@@ -494,6 +495,7 @@ namespace Emby.Dlna.PlayTo
                         return;
                     }
                 }
+
                 RestartTimerInactive();
             }
         }

+ 5 - 0
Emby.Dlna/PlayTo/PlayToController.cs

@@ -425,6 +425,7 @@ namespace Emby.Dlna.PlayTo
                     await _device.SetAvTransport(newItem.StreamUrl, GetDlnaHeaders(newItem), newItem.Didl, CancellationToken.None).ConfigureAwait(false);
                     return;
                 }
+
                 await SeekAfterTransportChange(newPosition, CancellationToken.None).ConfigureAwait(false);
             }
         }
@@ -713,6 +714,7 @@ namespace Emby.Dlna.PlayTo
 
                             throw new ArgumentException("Volume argument cannot be null");
                         }
+
                     default:
                         return Task.CompletedTask;
                 }
@@ -798,12 +800,15 @@ namespace Emby.Dlna.PlayTo
             public int? SubtitleStreamIndex { get; set; }
 
             public string DeviceProfileId { get; set; }
+
             public string DeviceId { get; set; }
 
             public string MediaSourceId { get; set; }
+
             public string LiveStreamId { get; set; }
 
             public BaseItem Item { get; set; }
+
             private MediaSourceInfo MediaSource;
 
             private IMediaSourceManager _mediaSourceManager;

+ 1 - 0
Emby.Dlna/PlayTo/PlayToManager.cs

@@ -132,6 +132,7 @@ namespace Emby.Dlna.PlayTo
                 usn = usn.Substring(index);
                 found = true;
             }
+
             index = usn.IndexOf("::", StringComparison.OrdinalIgnoreCase);
             if (index != -1)
             {

+ 1 - 0
Emby.Dlna/PlayTo/PlaybackStoppedEventArgs.cs

@@ -12,6 +12,7 @@ namespace Emby.Dlna.PlayTo
     public class MediaChangedEventArgs : EventArgs
     {
         public uBaseObject OldMediaInfo { get; set; }
+
         public uBaseObject NewMediaInfo { get; set; }
     }
 }

+ 2 - 0
Emby.Dlna/PlayTo/uBaseObject.cs

@@ -44,10 +44,12 @@ namespace Emby.Dlna.PlayTo
                 {
                     return MediaBrowser.Model.Entities.MediaType.Audio;
                 }
+
                 if (classType.IndexOf(MediaBrowser.Model.Entities.MediaType.Video, StringComparison.Ordinal) != -1)
                 {
                     return MediaBrowser.Model.Entities.MediaType.Video;
                 }
+
                 if (classType.IndexOf("image", StringComparison.Ordinal) != -1)
                 {
                     return MediaBrowser.Model.Entities.MediaType.Photo;

+ 5 - 0
Emby.Dlna/Server/DescriptionXmlBuilder.cs

@@ -134,6 +134,7 @@ namespace Emby.Dlna.Server
                     return result;
                 }
             }
+
             return c.ToString(CultureInfo.InvariantCulture);
         }
 
@@ -157,18 +158,22 @@ namespace Emby.Dlna.Server
                 {
                     break;
                 }
+
                 if (stringBuilder == null)
                 {
                     stringBuilder = new StringBuilder();
                 }
+
                 stringBuilder.Append(str, num, num2 - num);
                 stringBuilder.Append(GetEscapeSequence(str[num2]));
                 num = num2 + 1;
             }
+
             if (stringBuilder == null)
             {
                 return str;
             }
+
             stringBuilder.Append(str, num, length - num);
             return stringBuilder.ToString();
         }

+ 4 - 0
Emby.Dlna/Service/BaseControlHandler.cs

@@ -18,6 +18,7 @@ namespace Emby.Dlna.Service
         private const string NS_SOAPENV = "http://schemas.xmlsoap.org/soap/envelope/";
 
         protected IServerConfigurationManager Config { get; }
+
         protected ILogger Logger { get; }
 
         protected BaseControlHandler(IServerConfigurationManager config, ILogger logger)
@@ -135,6 +136,7 @@ namespace Emby.Dlna.Service
 
                                 break;
                             }
+
                         default:
                             {
                                 await reader.SkipAsync().ConfigureAwait(false);
@@ -211,7 +213,9 @@ namespace Emby.Dlna.Service
         private class ControlRequestInfo
         {
             public string LocalName { get; set; }
+
             public string NamespaceURI { get; set; }
+
             public Dictionary<string, string> Headers { get; } = new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase);
         }
 

+ 1 - 0
Emby.Dlna/Service/ServiceXmlBuilder.cs

@@ -80,6 +80,7 @@ namespace Emby.Dlna.Service
                     {
                         builder.Append("<allowedValue>" + DescriptionXmlBuilder.Escape(allowedValue) + "</allowedValue>");
                     }
+
                     builder.Append("</allowedValueList>");
                 }
 

+ 1 - 0
Emby.Naming/AudioBook/AudioBookFilePathParser.cs

@@ -64,6 +64,7 @@ namespace Emby.Naming.AudioBook
                 {
                     result.ChapterNumber = int.Parse(matches[0].Groups[0].Value);
                 }
+
                 if (matches.Count > 1)
                 {
                     result.PartNumber = int.Parse(matches[matches.Count - 1].Groups[0].Value);

+ 115 - 0
Emby.Server.Implementations/Data/SqliteItemRepository.cs

@@ -793,6 +793,7 @@ namespace Emby.Server.Implementations.Data
             {
                 saveItemStatement.TryBindNull("@Width");
             }
+
             if (item.Height > 0)
             {
                 saveItemStatement.TryBind("@Height", item.Height);
@@ -932,6 +933,7 @@ namespace Emby.Server.Implementations.Data
             {
                 saveItemStatement.TryBindNull("@SeriesName");
             }
+
             if (string.IsNullOrWhiteSpace(userDataKey))
             {
                 saveItemStatement.TryBindNull("@UserDataKey");
@@ -1007,6 +1009,7 @@ namespace Emby.Server.Implementations.Data
             {
                 artists = string.Join("|", hasArtists.Artists);
             }
+
             saveItemStatement.TryBind("@Artists", artists);
 
             string albumArtists = null;
@@ -1106,6 +1109,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     continue;
                 }
+
                 str.Append(ToValueString(i) + "|");
             }
 
@@ -1366,6 +1370,7 @@ namespace Emby.Server.Implementations.Data
                         hasStartDate.StartDate = reader[index].ReadDateTime();
                     }
                 }
+
                 index++;
             }
 
@@ -1373,12 +1378,14 @@ namespace Emby.Server.Implementations.Data
             {
                 item.EndDate = reader[index].TryReadDateTime();
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
             {
                 item.ChannelId = new Guid(reader.GetString(index));
             }
+
             index++;
 
             if (enableProgramAttributes)
@@ -1389,24 +1396,28 @@ namespace Emby.Server.Implementations.Data
                     {
                         hasProgramAttributes.IsMovie = reader.GetBoolean(index);
                     }
+
                     index++;
 
                     if (!reader.IsDBNull(index))
                     {
                         hasProgramAttributes.IsSeries = reader.GetBoolean(index);
                     }
+
                     index++;
 
                     if (!reader.IsDBNull(index))
                     {
                         hasProgramAttributes.EpisodeTitle = reader.GetString(index);
                     }
+
                     index++;
 
                     if (!reader.IsDBNull(index))
                     {
                         hasProgramAttributes.IsRepeat = reader.GetBoolean(index);
                     }
+
                     index++;
                 }
                 else
@@ -1419,6 +1430,7 @@ namespace Emby.Server.Implementations.Data
             {
                 item.CommunityRating = reader.GetFloat(index);
             }
+
             index++;
 
             if (HasField(query, ItemFields.CustomRating))
@@ -1427,6 +1439,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.CustomRating = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1434,6 +1447,7 @@ namespace Emby.Server.Implementations.Data
             {
                 item.IndexNumber = reader.GetInt32(index);
             }
+
             index++;
 
             if (HasField(query, ItemFields.Settings))
@@ -1442,18 +1456,21 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.IsLocked = reader.GetBoolean(index);
                 }
+
                 index++;
 
                 if (!reader.IsDBNull(index))
                 {
                     item.PreferredMetadataLanguage = reader.GetString(index);
                 }
+
                 index++;
 
                 if (!reader.IsDBNull(index))
                 {
                     item.PreferredMetadataCountryCode = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1463,6 +1480,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.Width = reader.GetInt32(index);
                 }
+
                 index++;
             }
 
@@ -1472,6 +1490,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.Height = reader.GetInt32(index);
                 }
+
                 index++;
             }
 
@@ -1481,6 +1500,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.DateLastRefreshed = reader[index].ReadDateTime();
                 }
+
                 index++;
             }
 
@@ -1488,18 +1508,21 @@ namespace Emby.Server.Implementations.Data
             {
                 item.Name = reader.GetString(index);
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
             {
                 item.Path = RestorePath(reader.GetString(index));
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
             {
                 item.PremiereDate = reader[index].TryReadDateTime();
             }
+
             index++;
 
             if (HasField(query, ItemFields.Overview))
@@ -1508,6 +1531,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.Overview = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1515,18 +1539,21 @@ namespace Emby.Server.Implementations.Data
             {
                 item.ParentIndexNumber = reader.GetInt32(index);
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
             {
                 item.ProductionYear = reader.GetInt32(index);
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
             {
                 item.OfficialRating = reader.GetString(index);
             }
+
             index++;
 
             if (HasField(query, ItemFields.SortName))
@@ -1535,6 +1562,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.ForcedSortName = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1542,12 +1570,14 @@ namespace Emby.Server.Implementations.Data
             {
                 item.RunTimeTicks = reader.GetInt64(index);
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
             {
                 item.Size = reader.GetInt64(index);
             }
+
             index++;
 
             if (HasField(query, ItemFields.DateCreated))
@@ -1556,6 +1586,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.DateCreated = reader[index].ReadDateTime();
                 }
+
                 index++;
             }
 
@@ -1563,6 +1594,7 @@ namespace Emby.Server.Implementations.Data
             {
                 item.DateModified = reader[index].ReadDateTime();
             }
+
             index++;
 
             item.Id = reader.GetGuid(index);
@@ -1574,6 +1606,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.Genres = reader.GetString(index).Split(new[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
                 }
+
                 index++;
             }
 
@@ -1581,6 +1614,7 @@ namespace Emby.Server.Implementations.Data
             {
                 item.ParentId = reader.GetGuid(index);
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
@@ -1590,6 +1624,7 @@ namespace Emby.Server.Implementations.Data
                     item.Audio = audio;
                 }
             }
+
             index++;
 
             // TODO: Even if not needed by apps, the server needs it internally
@@ -1603,6 +1638,7 @@ namespace Emby.Server.Implementations.Data
                         liveTvChannel.ServiceName = reader.GetString(index);
                     }
                 }
+
                 index++;
             }
 
@@ -1610,6 +1646,7 @@ namespace Emby.Server.Implementations.Data
             {
                 item.IsInMixedFolder = reader.GetBoolean(index);
             }
+
             index++;
 
             if (HasField(query, ItemFields.DateLastSaved))
@@ -1618,6 +1655,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.DateLastSaved = reader[index].ReadDateTime();
                 }
+
                 index++;
             }
 
@@ -1635,8 +1673,10 @@ namespace Emby.Server.Implementations.Data
                             }
                         }
                     }
+
                     item.LockedFields = GetLockedFields(reader.GetString(index)).ToArray();
                 }
+
                 index++;
             }
 
@@ -1646,6 +1686,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.Studios = reader.GetString(index).Split(new[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
                 }
+
                 index++;
             }
 
@@ -1655,6 +1696,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.Tags = reader.GetString(index).Split(new[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
                 }
+
                 index++;
             }
 
@@ -1674,9 +1716,11 @@ namespace Emby.Server.Implementations.Data
                                 }
                             }
                         }
+
                         trailer.TrailerTypes = GetTrailerTypes(reader.GetString(index)).ToArray();
                     }
                 }
+
                 index++;
             }
 
@@ -1686,6 +1730,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.OriginalTitle = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1696,6 +1741,7 @@ namespace Emby.Server.Implementations.Data
                     video.PrimaryVersionId = reader.GetString(index);
                 }
             }
+
             index++;
 
             if (HasField(query, ItemFields.DateLastMediaAdded))
@@ -1704,6 +1750,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     folder.DateLastMediaAdded = reader[index].TryReadDateTime();
                 }
+
                 index++;
             }
 
@@ -1711,18 +1758,21 @@ namespace Emby.Server.Implementations.Data
             {
                 item.Album = reader.GetString(index);
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
             {
                 item.CriticRating = reader.GetFloat(index);
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
             {
                 item.IsVirtualItem = reader.GetBoolean(index);
             }
+
             index++;
 
             if (item is IHasSeries hasSeriesName)
@@ -1732,6 +1782,7 @@ namespace Emby.Server.Implementations.Data
                     hasSeriesName.SeriesName = reader.GetString(index);
                 }
             }
+
             index++;
 
             if (hasEpisodeAttributes)
@@ -1742,6 +1793,7 @@ namespace Emby.Server.Implementations.Data
                     {
                         episode.SeasonName = reader.GetString(index);
                     }
+
                     index++;
                     if (!reader.IsDBNull(index))
                     {
@@ -1752,6 +1804,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     index++;
                 }
+
                 index++;
             }
 
@@ -1765,6 +1818,7 @@ namespace Emby.Server.Implementations.Data
                         hasSeries.SeriesId = reader.GetGuid(index);
                     }
                 }
+
                 index++;
             }
 
@@ -1774,6 +1828,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.PresentationUniqueKey = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1783,6 +1838,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.InheritedParentalRatingValue = reader.GetInt32(index);
                 }
+
                 index++;
             }
 
@@ -1792,6 +1848,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.ExternalSeriesId = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1801,6 +1858,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.Tagline = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1808,6 +1866,7 @@ namespace Emby.Server.Implementations.Data
             {
                 DeserializeProviderIds(reader.GetString(index), item);
             }
+
             index++;
 
             if (query.DtoOptions.EnableImages)
@@ -1816,6 +1875,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     DeserializeImages(reader.GetString(index), item);
                 }
+
                 index++;
             }
 
@@ -1825,6 +1885,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.ProductionLocations = reader.GetString(index).Split(new[] { '|' }, StringSplitOptions.RemoveEmptyEntries).ToArray();
                 }
+
                 index++;
             }
 
@@ -1834,6 +1895,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     item.ExtraIds = SplitToGuids(reader.GetString(index));
                 }
+
                 index++;
             }
 
@@ -1841,6 +1903,7 @@ namespace Emby.Server.Implementations.Data
             {
                 item.TotalBitrate = reader.GetInt32(index);
             }
+
             index++;
 
             if (!reader.IsDBNull(index))
@@ -1850,6 +1913,7 @@ namespace Emby.Server.Implementations.Data
                     item.ExtraType = extraType;
                 }
             }
+
             index++;
 
             if (hasArtistFields)
@@ -1858,12 +1922,14 @@ namespace Emby.Server.Implementations.Data
                 {
                     hasArtists.Artists = reader.GetString(index).Split(new[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
                 }
+
                 index++;
 
                 if (item is IHasAlbumArtist hasAlbumArtists && !reader.IsDBNull(index))
                 {
                     hasAlbumArtists.AlbumArtists = reader.GetString(index).Split(new[] { '|' }, StringSplitOptions.RemoveEmptyEntries);
                 }
+
                 index++;
             }
 
@@ -1871,6 +1937,7 @@ namespace Emby.Server.Implementations.Data
             {
                 item.ExternalId = reader.GetString(index);
             }
+
             index++;
 
             if (HasField(query, ItemFields.SeriesPresentationUniqueKey))
@@ -1882,6 +1949,7 @@ namespace Emby.Server.Implementations.Data
                         hasSeries.SeriesPresentationUniqueKey = reader.GetString(index);
                     }
                 }
+
                 index++;
             }
 
@@ -1891,6 +1959,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     program.ShowId = reader.GetString(index);
                 }
+
                 index++;
             }
 
@@ -1898,6 +1967,7 @@ namespace Emby.Server.Implementations.Data
             {
                 item.OwnerId = reader.GetGuid(index);
             }
+
             index++;
 
             return item;
@@ -2473,6 +2543,7 @@ namespace Emby.Server.Implementations.Data
             {
                 statement.TryBind("@SearchTermStartsWith", searchTerm + "%");
             }
+
             if (commandText.IndexOf("@SearchTermContains", StringComparison.OrdinalIgnoreCase) != -1)
             {
                 statement.TryBind("@SearchTermContains", "%" + searchTerm + "%");
@@ -2743,6 +2814,7 @@ namespace Emby.Server.Implementations.Data
                         {
                             items[i] = newItem;
                         }
+
                         return;
                     }
                 }
@@ -2835,6 +2907,7 @@ namespace Emby.Server.Implementations.Data
             {
                 statementTexts.Add(commandText);
             }
+
             if (query.EnableTotalRecordCount)
             {
                 commandText = string.Empty;
@@ -3239,6 +3312,7 @@ namespace Emby.Server.Implementations.Data
             {
                 statementTexts.Add(commandText);
             }
+
             if (query.EnableTotalRecordCount)
             {
                 commandText = string.Empty;
@@ -3592,11 +3666,13 @@ namespace Emby.Server.Implementations.Data
                 whereClauses.Add("IndexNumber=@IndexNumber");
                 statement?.TryBind("@IndexNumber", query.IndexNumber.Value);
             }
+
             if (query.ParentIndexNumber.HasValue)
             {
                 whereClauses.Add("ParentIndexNumber=@ParentIndexNumber");
                 statement?.TryBind("@ParentIndexNumber", query.ParentIndexNumber.Value);
             }
+
             if (query.ParentIndexNumberNotEquals.HasValue)
             {
                 whereClauses.Add("(ParentIndexNumber<>@ParentIndexNumberNotEquals or ParentIndexNumber is null)");
@@ -3882,6 +3958,7 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, artistId.ToByteArray());
                     }
+
                     index++;
                 }
 
@@ -3902,6 +3979,7 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, artistId.ToByteArray());
                     }
+
                     index++;
                 }
 
@@ -3922,8 +4000,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, artistId.ToByteArray());
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -3941,8 +4021,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, albumId.ToByteArray());
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -3960,8 +4042,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, artistId.ToByteArray());
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -3979,8 +4063,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, genreId.ToByteArray());
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -3996,8 +4082,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind("@Genre" + index, GetCleanValue(item));
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -4013,8 +4101,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind("@Tag" + index, GetCleanValue(item));
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -4030,8 +4120,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind("@ExcludeTag" + index, GetCleanValue(item));
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -4050,8 +4142,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, studioId.ToByteArray());
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -4067,8 +4161,10 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind("@OfficialRating" + index, item);
                     }
+
                     index++;
                 }
+
                 var clause = "(" + string.Join(" OR ", clauses) + ")";
                 whereClauses.Add(clause);
             }
@@ -4243,6 +4339,7 @@ namespace Emby.Server.Implementations.Data
                     statement.TryBind("@IsVirtualItem", isVirtualItem.Value);
                 }
             }
+
             if (query.IsSpecialSeason.HasValue)
             {
                 if (query.IsSpecialSeason.Value)
@@ -4254,6 +4351,7 @@ namespace Emby.Server.Implementations.Data
                     whereClauses.Add("IndexNumber <> 0");
                 }
             }
+
             if (query.IsUnaired.HasValue)
             {
                 if (query.IsUnaired.Value)
@@ -4265,6 +4363,7 @@ namespace Emby.Server.Implementations.Data
                     whereClauses.Add("PremiereDate < DATETIME('now')");
                 }
             }
+
             var queryMediaTypes = query.MediaTypes.Where(IsValidMediaType).ToArray();
             if (queryMediaTypes.Length == 1)
             {
@@ -4280,6 +4379,7 @@ namespace Emby.Server.Implementations.Data
 
                 whereClauses.Add("MediaType in (" + val + ")");
             }
+
             if (query.ItemIds.Length > 0)
             {
                 var includeIds = new List<string>();
@@ -4292,11 +4392,13 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind("@IncludeId" + index, id);
                     }
+
                     index++;
                 }
 
                 whereClauses.Add("(" + string.Join(" OR ", includeIds) + ")");
             }
+
             if (query.ExcludeItemIds.Length > 0)
             {
                 var excludeIds = new List<string>();
@@ -4309,6 +4411,7 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind("@ExcludeId" + index, id);
                     }
+
                     index++;
                 }
 
@@ -4333,6 +4436,7 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, "%" + pair.Key + "=" + pair.Value + "%");
                     }
+
                     index++;
 
                     break;
@@ -4375,6 +4479,7 @@ namespace Emby.Server.Implementations.Data
                     {
                         statement.TryBind(paramName, "%" + pair.Key + "=" + pair.Value + "%");
                     }
+
                     index++;
 
                     break;
@@ -4425,6 +4530,7 @@ namespace Emby.Server.Implementations.Data
                 {
                     whereClauses.Add("(TopParentId=@TopParentId)");
                 }
+
                 if (statement != null)
                 {
                     statement.TryBind("@TopParentId", queryTopParentIds[0].ToString("N", CultureInfo.InvariantCulture));
@@ -4462,11 +4568,13 @@ namespace Emby.Server.Implementations.Data
                     statement.TryBind("@AncestorId", query.AncestorIds[0]);
                 }
             }
+
             if (query.AncestorIds.Length > 1)
             {
                 var inClause = string.Join(",", query.AncestorIds.Select(i => "'" + i.ToString("N", CultureInfo.InvariantCulture) + "'"));
                 whereClauses.Add(string.Format("Guid in (select itemId from AncestorIds where AncestorIdText in ({0}))", inClause));
             }
+
             if (!string.IsNullOrWhiteSpace(query.AncestorWithPresentationUniqueKey))
             {
                 var inClause = "select guid from TypedBaseItems where PresentationUniqueKey=@AncestorWithPresentationUniqueKey";
@@ -4495,6 +4603,7 @@ namespace Emby.Server.Implementations.Data
                     statement.TryBind("@UnratedType", query.BlockUnratedItems[0].ToString());
                 }
             }
+
             if (query.BlockUnratedItems.Length > 1)
             {
                 var inClause = string.Join(",", query.BlockUnratedItems.Select(i => "'" + i.ToString() + "'"));
@@ -4969,6 +5078,7 @@ where AncestorIdText not null and ItemValues.Value not null and ItemValues.Type
                     statement.TryBind("@ItemId", query.ItemId.ToByteArray());
                 }
             }
+
             if (!query.AppearsInItemId.Equals(Guid.Empty))
             {
                 whereClauses.Add("Name in (Select Name from People where ItemId=@AppearsInItemId)");
@@ -4977,6 +5087,7 @@ where AncestorIdText not null and ItemValues.Value not null and ItemValues.Type
                     statement.TryBind("@AppearsInItemId", query.AppearsInItemId.ToByteArray());
                 }
             }
+
             var queryPersonTypes = query.PersonTypes.Where(IsValidPersonType).ToList();
 
             if (queryPersonTypes.Count == 1)
@@ -4993,6 +5104,7 @@ where AncestorIdText not null and ItemValues.Value not null and ItemValues.Type
 
                 whereClauses.Add("PersonType in (" + val + ")");
             }
+
             var queryExcludePersonTypes = query.ExcludePersonTypes.Where(IsValidPersonType).ToList();
 
             if (queryExcludePersonTypes.Count == 1)
@@ -5009,6 +5121,7 @@ where AncestorIdText not null and ItemValues.Value not null and ItemValues.Type
 
                 whereClauses.Add("PersonType not in (" + val + ")");
             }
+
             if (query.MaxListOrder.HasValue)
             {
                 whereClauses.Add("ListOrder<=@MaxListOrder");
@@ -5017,6 +5130,7 @@ where AncestorIdText not null and ItemValues.Value not null and ItemValues.Type
                     statement.TryBind("@MaxListOrder", query.MaxListOrder.Value);
                 }
             }
+
             if (!string.IsNullOrWhiteSpace(query.NameContains))
             {
                 whereClauses.Add("Name like @NameContains");
@@ -5156,6 +5270,7 @@ where AncestorIdText not null and ItemValues.Value not null and ItemValues.Type
                 var typeString = string.Join(",", withItemTypes.Select(i => "'" + i + "'"));
                 commandText += " AND ItemId In (select guid from typedbaseitems where type in (" + typeString + "))";
             }
+
             if (excludeItemTypes.Count > 0)
             {
                 var typeString = string.Join(",", excludeItemTypes.Select(i => "'" + i + "'"));

+ 3 - 0
Emby.Server.Implementations/Data/SqliteUserDataRepository.cs

@@ -135,10 +135,12 @@ namespace Emby.Server.Implementations.Data
             {
                 throw new ArgumentNullException(nameof(userData));
             }
+
             if (internalUserId <= 0)
             {
                 throw new ArgumentNullException(nameof(internalUserId));
             }
+
             if (string.IsNullOrEmpty(key))
             {
                 throw new ArgumentNullException(nameof(key));
@@ -153,6 +155,7 @@ namespace Emby.Server.Implementations.Data
             {
                 throw new ArgumentNullException(nameof(userData));
             }
+
             if (internalUserId <= 0)
             {
                 throw new ArgumentNullException(nameof(internalUserId));

+ 1 - 0
Emby.Server.Implementations/Devices/DeviceManager.cs

@@ -169,6 +169,7 @@ namespace Emby.Server.Implementations.Devices
             {
                 throw new ArgumentException("user not found");
             }
+
             if (string.IsNullOrEmpty(deviceId))
             {
                 throw new ArgumentNullException(nameof(deviceId));

+ 11 - 0
Emby.Server.Implementations/Dto/DtoService.cs

@@ -277,6 +277,7 @@ namespace Emby.Server.Implementations.Dto
                     dto.EpisodeTitle = dto.Name;
                     dto.Name = dto.SeriesName;
                 }
+
                 liveTvManager.AddInfoToRecordingDto(item, dto, activeRecording, user);
             }
 
@@ -292,6 +293,7 @@ namespace Emby.Server.Implementations.Dto
                 {
                     continue;
                 }
+
                 var containers = container.Split(new[] { ',' });
                 if (containers.Length < 2)
                 {
@@ -456,6 +458,7 @@ namespace Emby.Server.Implementations.Dto
         {
             dto.SeriesName = item.SeriesName;
         }
+
         private static void SetPhotoProperties(BaseItemDto dto, Photo item)
         {
             dto.CameraMake = item.CameraMake;
@@ -554,22 +557,27 @@ namespace Emby.Server.Implementations.Dto
                     {
                         return 0;
                     }
+
                     if (i.IsType(PersonType.GuestStar))
                     {
                         return 1;
                     }
+
                     if (i.IsType(PersonType.Director))
                     {
                         return 2;
                     }
+
                     if (i.IsType(PersonType.Writer))
                     {
                         return 3;
                     }
+
                     if (i.IsType(PersonType.Producer))
                     {
                         return 4;
                     }
+
                     if (i.IsType(PersonType.Composer))
                     {
                         return 4;
@@ -1346,6 +1354,7 @@ namespace Emby.Server.Implementations.Dto
                         dto.ParentLogoImageTag = GetTagAndFillBlurhash(dto, parent, image);
                     }
                 }
+
                 if (artLimit > 0 && !(imageTags != null && imageTags.ContainsKey(ImageType.Art)) && dto.ParentArtItemId == null)
                 {
                     var image = allImages.FirstOrDefault(i => i.Type == ImageType.Art);
@@ -1356,6 +1365,7 @@ namespace Emby.Server.Implementations.Dto
                         dto.ParentArtImageTag = GetTagAndFillBlurhash(dto, parent, image);
                     }
                 }
+
                 if (thumbLimit > 0 && !(imageTags != null && imageTags.ContainsKey(ImageType.Thumb)) && (dto.ParentThumbItemId == null || parent is Series) && !(parent is ICollectionFolder) && !(parent is UserView))
                 {
                     var image = allImages.FirstOrDefault(i => i.Type == ImageType.Thumb);
@@ -1366,6 +1376,7 @@ namespace Emby.Server.Implementations.Dto
                         dto.ParentThumbImageTag = GetTagAndFillBlurhash(dto, parent, image);
                     }
                 }
+
                 if (backdropLimit > 0 && !((dto.BackdropImageTags != null && dto.BackdropImageTags.Length > 0) || (dto.ParentBackdropImageTags != null && dto.ParentBackdropImageTags.Length > 0)))
                 {
                     var images = allImages.Where(i => i.Type == ImageType.Backdrop).Take(backdropLimit).ToList();

+ 1 - 0
Emby.Server.Implementations/HttpServer/HttpListenerHost.cs

@@ -453,6 +453,7 @@ namespace Emby.Server.Implementations.HttpServer
                     {
                         httpRes.Headers.Add(key, value);
                     }
+
                     httpRes.ContentType = "text/plain";
                     await httpRes.WriteAsync(string.Empty, cancellationToken).ConfigureAwait(false);
                     return;

+ 7 - 0
Emby.Server.Implementations/HttpServer/RangeRequestWriter.cs

@@ -20,15 +20,21 @@ namespace Emby.Server.Implementations.HttpServer
         /// </summary>
         /// <value>The source stream.</value>
         private Stream SourceStream { get; set; }
+
         private string RangeHeader { get; set; }
+
         private bool IsHeadRequest { get; set; }
 
         private long RangeStart { get; set; }
+
         private long RangeEnd { get; set; }
+
         private long RangeLength { get; set; }
+
         private long TotalContentLength { get; set; }
 
         public Action OnComplete { get; set; }
+
         private readonly ILogger _logger;
 
         private const int BufferSize = 81920;
@@ -139,6 +145,7 @@ namespace Emby.Server.Implementations.HttpServer
                         {
                             start = long.Parse(vals[0], UsCulture);
                         }
+
                         if (!string.IsNullOrEmpty(vals[1]))
                         {
                             end = long.Parse(vals[1], UsCulture);

+ 1 - 0
Emby.Server.Implementations/HttpServer/Security/AuthService.cs

@@ -140,6 +140,7 @@ namespace Emby.Server.Implementations.HttpServer.Security
             {
                 return true;
             }
+
             if (authAttribtues.AllowLocalOnly && request.IsLocal)
             {
                 return true;

+ 2 - 0
Emby.Server.Implementations/HttpServer/Security/AuthorizationContext.cs

@@ -71,6 +71,7 @@ namespace Emby.Server.Implementations.HttpServer.Security
             {
                 token = httpReq.Headers["X-MediaBrowser-Token"];
             }
+
             if (string.IsNullOrEmpty(token))
             {
                 token = httpReq.QueryString["api_key"];
@@ -160,6 +161,7 @@ namespace Emby.Server.Implementations.HttpServer.Security
                         _authRepo.Update(tokenInfo);
                     }
                 }
+
                 httpReq.Items["OriginalAuthenticationInfo"] = tokenInfo;
             }
 

+ 2 - 0
Emby.Server.Implementations/IO/ManagedFileSystem.cs

@@ -628,6 +628,7 @@ namespace Emby.Server.Implementations.IO
                     {
                         return false;
                     }
+
                     return extensions.Contains(ext, StringComparer.OrdinalIgnoreCase);
                 });
             }
@@ -682,6 +683,7 @@ namespace Emby.Server.Implementations.IO
                     {
                         return false;
                     }
+
                     return extensions.Contains(ext, StringComparer.OrdinalIgnoreCase);
                 });
             }

+ 2 - 0
Emby.Server.Implementations/Library/ExclusiveLiveStream.cs

@@ -12,11 +12,13 @@ namespace Emby.Server.Implementations.Library
     public class ExclusiveLiveStream : ILiveStream
     {
         public int ConsumerCount { get; set; }
+
         public string OriginalStreamId { get; set; }
 
         public string TunerHostId => null;
 
         public bool EnableStreamSharing { get; set; }
+
         public MediaSourceInfo MediaSource { get; set; }
 
         public string UniqueId { get; private set; }

+ 2 - 0
Emby.Server.Implementations/Library/LibraryManager.cs

@@ -2784,10 +2784,12 @@ namespace Emby.Server.Implementations.Library
             {
                 throw new ArgumentNullException(nameof(path));
             }
+
             if (string.IsNullOrWhiteSpace(from))
             {
                 throw new ArgumentNullException(nameof(from));
             }
+
             if (string.IsNullOrWhiteSpace(to))
             {
                 throw new ArgumentNullException(nameof(to));

+ 5 - 0
Emby.Server.Implementations/Library/MediaSourceManager.cs

@@ -205,22 +205,27 @@ namespace Emby.Server.Implementations.Library
             {
                 return MediaProtocol.Rtsp;
             }
+
             if (path.StartsWith("Rtmp", StringComparison.OrdinalIgnoreCase))
             {
                 return MediaProtocol.Rtmp;
             }
+
             if (path.StartsWith("Http", StringComparison.OrdinalIgnoreCase))
             {
                 return MediaProtocol.Http;
             }
+
             if (path.StartsWith("rtp", StringComparison.OrdinalIgnoreCase))
             {
                 return MediaProtocol.Rtp;
             }
+
             if (path.StartsWith("ftp", StringComparison.OrdinalIgnoreCase))
             {
                 return MediaProtocol.Ftp;
             }
+
             if (path.StartsWith("udp", StringComparison.OrdinalIgnoreCase))
             {
                 return MediaProtocol.Udp;

+ 2 - 0
Emby.Server.Implementations/Library/Resolvers/SpecialFolderResolver.cs

@@ -41,10 +41,12 @@ namespace Emby.Server.Implementations.Library.Resolvers
                 {
                     return new AggregateFolder();
                 }
+
                 if (string.Equals(args.Path, _appPaths.DefaultUserViewsPath, StringComparison.OrdinalIgnoreCase))
                 {
                     return new UserRootFolder();  // if we got here and still a root - must be user root
                 }
+
                 if (args.IsVf)
                 {
                     return new CollectionFolder

+ 1 - 0
Emby.Server.Implementations/Library/Resolvers/TV/EpisodeResolver.cs

@@ -55,6 +55,7 @@ namespace Emby.Server.Implementations.Library.Resolvers.TV
                         episode.SeriesId = series.Id;
                         episode.SeriesName = series.Name;
                     }
+
                     if (season != null)
                     {
                         episode.SeasonId = season.Id;

+ 1 - 0
Emby.Server.Implementations/Library/SearchEngine.cs

@@ -194,6 +194,7 @@ namespace Emby.Server.Implementations.Library
                 {
                     searchQuery.AncestorIds = new[] { searchQuery.ParentId };
                 }
+
                 searchQuery.ParentId = Guid.Empty;
                 searchQuery.IncludeItemsByName = true;
                 searchQuery.IncludeItemTypes = Array.Empty<string>();

+ 118 - 0
Emby.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs

@@ -212,6 +212,7 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             {
                 channelNumber = map.channel;
             }
+
             if (string.IsNullOrWhiteSpace(channelNumber))
             {
                 channelNumber = map.atscMajor + "." + map.atscMinor;
@@ -400,6 +401,7 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             {
                 date = DateTime.SpecifyKind(date, DateTimeKind.Utc);
             }
+
             return date;
         }
 
@@ -622,6 +624,7 @@ namespace Emby.Server.Implementations.LiveTv.Listings
                         _lastErrorResponse = DateTime.UtcNow;
                     }
                 }
+
                 throw;
             }
             finally
@@ -805,11 +808,13 @@ namespace Emby.Server.Implementations.LiveTv.Listings
                 {
                     throw new ArgumentException("Username is required");
                 }
+
                 if (string.IsNullOrEmpty(info.Password))
                 {
                     throw new ArgumentException("Password is required");
                 }
             }
+
             if (validateListings)
             {
                 if (string.IsNullOrEmpty(info.ListingsId))
@@ -932,24 +937,35 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             public class Token
             {
                 public int code { get; set; }
+
                 public string message { get; set; }
+
                 public string serverID { get; set; }
+
                 public string token { get; set; }
             }
+
             public class Lineup
             {
                 public string lineup { get; set; }
+
                 public string name { get; set; }
+
                 public string transport { get; set; }
+
                 public string location { get; set; }
+
                 public string uri { get; set; }
             }
 
             public class Lineups
             {
                 public int code { get; set; }
+
                 public string serverID { get; set; }
+
                 public string datetime { get; set; }
+
                 public List<Lineup> lineups { get; set; }
             }
 
@@ -957,8 +973,11 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             public class Headends
             {
                 public string headend { get; set; }
+
                 public string transport { get; set; }
+
                 public string location { get; set; }
+
                 public List<Lineup> lineups { get; set; }
             }
 
@@ -967,59 +986,83 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             public class Map
             {
                 public string stationID { get; set; }
+
                 public string channel { get; set; }
+
                 public string logicalChannelNumber { get; set; }
+
                 public int uhfVhf { get; set; }
+
                 public int atscMajor { get; set; }
+
                 public int atscMinor { get; set; }
             }
 
             public class Broadcaster
             {
                 public string city { get; set; }
+
                 public string state { get; set; }
+
                 public string postalcode { get; set; }
+
                 public string country { get; set; }
             }
 
             public class Logo
             {
                 public string URL { get; set; }
+
                 public int height { get; set; }
+
                 public int width { get; set; }
+
                 public string md5 { get; set; }
             }
 
             public class Station
             {
                 public string stationID { get; set; }
+
                 public string name { get; set; }
+
                 public string callsign { get; set; }
+
                 public List<string> broadcastLanguage { get; set; }
+
                 public List<string> descriptionLanguage { get; set; }
+
                 public Broadcaster broadcaster { get; set; }
+
                 public string affiliate { get; set; }
+
                 public Logo logo { get; set; }
+
                 public bool? isCommercialFree { get; set; }
             }
 
             public class Metadata
             {
                 public string lineup { get; set; }
+
                 public string modified { get; set; }
+
                 public string transport { get; set; }
             }
 
             public class Channel
             {
                 public List<Map> map { get; set; }
+
                 public List<Station> stations { get; set; }
+
                 public Metadata metadata { get; set; }
             }
 
             public class RequestScheduleForChannel
             {
                 public string stationID { get; set; }
+
                 public List<string> date { get; set; }
             }
 
@@ -1029,29 +1072,43 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             public class Rating
             {
                 public string body { get; set; }
+
                 public string code { get; set; }
             }
 
             public class Multipart
             {
                 public int partNumber { get; set; }
+
                 public int totalParts { get; set; }
             }
 
             public class Program
             {
                 public string programID { get; set; }
+
                 public string airDateTime { get; set; }
+
                 public int duration { get; set; }
+
                 public string md5 { get; set; }
+
                 public List<string> audioProperties { get; set; }
+
                 public List<string> videoProperties { get; set; }
+
                 public List<Rating> ratings { get; set; }
+
                 public bool? @new { get; set; }
+
                 public Multipart multipart { get; set; }
+
                 public string liveTapeDelay { get; set; }
+
                 public bool premiere { get; set; }
+
                 public bool repeat { get; set; }
+
                 public string isPremiereOrFinale { get; set; }
             }
 
@@ -1060,16 +1117,22 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             public class MetadataSchedule
             {
                 public string modified { get; set; }
+
                 public string md5 { get; set; }
+
                 public string startDate { get; set; }
+
                 public string endDate { get; set; }
+
                 public int days { get; set; }
             }
 
             public class Day
             {
                 public string stationID { get; set; }
+
                 public List<Program> programs { get; set; }
+
                 public MetadataSchedule metadata { get; set; }
 
                 public Day()
@@ -1092,24 +1155,28 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             public class Description100
             {
                 public string descriptionLanguage { get; set; }
+
                 public string description { get; set; }
             }
 
             public class Description1000
             {
                 public string descriptionLanguage { get; set; }
+
                 public string description { get; set; }
             }
 
             public class DescriptionsProgram
             {
                 public List<Description100> description100 { get; set; }
+
                 public List<Description1000> description1000 { get; set; }
             }
 
             public class Gracenote
             {
                 public int season { get; set; }
+
                 public int episode { get; set; }
             }
 
@@ -1121,101 +1188,152 @@ namespace Emby.Server.Implementations.LiveTv.Listings
             public class ContentRating
             {
                 public string body { get; set; }
+
                 public string code { get; set; }
             }
 
             public class Cast
             {
                 public string billingOrder { get; set; }
+
                 public string role { get; set; }
+
                 public string nameId { get; set; }
+
                 public string personId { get; set; }
+
                 public string name { get; set; }
+
                 public string characterName { get; set; }
             }
 
             public class Crew
             {
                 public string billingOrder { get; set; }
+
                 public string role { get; set; }
+
                 public string nameId { get; set; }
+
                 public string personId { get; set; }
+
                 public string name { get; set; }
             }
 
             public class QualityRating
             {
                 public string ratingsBody { get; set; }
+
                 public string rating { get; set; }
+
                 public string minRating { get; set; }
+
                 public string maxRating { get; set; }
+
                 public string increment { get; set; }
             }
 
             public class Movie
             {
                 public string year { get; set; }
+
                 public int duration { get; set; }
+
                 public List<QualityRating> qualityRating { get; set; }
             }
 
             public class Recommendation
             {
                 public string programID { get; set; }
+
                 public string title120 { get; set; }
             }
 
             public class ProgramDetails
             {
                 public string audience { get; set; }
+
                 public string programID { get; set; }
+
                 public List<Title> titles { get; set; }
+
                 public EventDetails eventDetails { get; set; }
+
                 public DescriptionsProgram descriptions { get; set; }
+
                 public string originalAirDate { get; set; }
+
                 public List<string> genres { get; set; }
+
                 public string episodeTitle150 { get; set; }
+
                 public List<MetadataPrograms> metadata { get; set; }
+
                 public List<ContentRating> contentRating { get; set; }
+
                 public List<Cast> cast { get; set; }
+
                 public List<Crew> crew { get; set; }
+
                 public string entityType { get; set; }
+
                 public string showType { get; set; }
+
                 public bool hasImageArtwork { get; set; }
+
                 public string primaryImage { get; set; }
+
                 public string thumbImage { get; set; }
+
                 public string backdropImage { get; set; }
+
                 public string bannerImage { get; set; }
+
                 public string imageID { get; set; }
+
                 public string md5 { get; set; }
+
                 public List<string> contentAdvisory { get; set; }
+
                 public Movie movie { get; set; }
+
                 public List<Recommendation> recommendations { get; set; }
             }
 
             public class Caption
             {
                 public string content { get; set; }
+
                 public string lang { get; set; }
             }
 
             public class ImageData
             {
                 public string width { get; set; }
+
                 public string height { get; set; }
+
                 public string uri { get; set; }
+
                 public string size { get; set; }
+
                 public string aspect { get; set; }
+
                 public string category { get; set; }
+
                 public string text { get; set; }
+
                 public string primary { get; set; }
+
                 public string tier { get; set; }
+
                 public Caption caption { get; set; }
             }
 
             public class ShowImages
             {
                 public string programID { get; set; }
+
                 public List<ImageData> data { get; set; }
             }
         }

+ 1 - 0
Emby.Server.Implementations/LiveTv/Listings/XmlTvListingsProvider.cs

@@ -224,6 +224,7 @@ namespace Emby.Server.Implementations.LiveTv.Listings
                 {
                     uniqueString = "-" + programInfo.SeasonNumber.Value.ToString(CultureInfo.InvariantCulture);
                 }
+
                 if (programInfo.EpisodeNumber.HasValue)
                 {
                     uniqueString = "-" + programInfo.EpisodeNumber.Value.ToString(CultureInfo.InvariantCulture);

+ 12 - 0
Emby.Server.Implementations/LiveTv/LiveTvManager.cs

@@ -556,6 +556,7 @@ namespace Emby.Server.Implementations.LiveTv
             {
                 forceUpdate = true;
             }
+
             item.ParentId = channel.Id;
 
             // item.ChannelType = channelType;
@@ -575,6 +576,7 @@ namespace Emby.Server.Implementations.LiveTv
             {
                 forceUpdate = true;
             }
+
             item.ExternalSeriesId = seriesId;
 
             var isSeries = info.IsSeries || !string.IsNullOrEmpty(info.EpisodeTitle);
@@ -589,30 +591,37 @@ namespace Emby.Server.Implementations.LiveTv
             {
                 tags.Add("Live");
             }
+
             if (info.IsPremiere)
             {
                 tags.Add("Premiere");
             }
+
             if (info.IsNews)
             {
                 tags.Add("News");
             }
+
             if (info.IsSports)
             {
                 tags.Add("Sports");
             }
+
             if (info.IsKids)
             {
                 tags.Add("Kids");
             }
+
             if (info.IsRepeat)
             {
                 tags.Add("Repeat");
             }
+
             if (info.IsMovie)
             {
                 tags.Add("Movie");
             }
+
             if (isSeries)
             {
                 tags.Add("Series");
@@ -635,6 +644,7 @@ namespace Emby.Server.Implementations.LiveTv
             {
                 forceUpdate = true;
             }
+
             item.IsSeries = isSeries;
 
             item.Name = info.Name;
@@ -652,12 +662,14 @@ namespace Emby.Server.Implementations.LiveTv
             {
                 forceUpdate = true;
             }
+
             item.StartDate = info.StartDate;
 
             if (item.EndDate != info.EndDate)
             {
                 forceUpdate = true;
             }
+
             item.EndDate = info.EndDate;
 
             item.ProductionYear = info.ProductionYear;

+ 19 - 0
Emby.Server.Implementations/LiveTv/TunerHosts/HdHomerun/HdHomerunHost.cs

@@ -170,6 +170,7 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
                             _modelCache[cacheKey] = response;
                         }
                     }
+
                     return response;
                 }
 
@@ -201,6 +202,7 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
                         var name = line.Substring(0, index - 1);
                         var currentChannel = line.Substring(index + 7);
                         if (currentChannel != "none") { status = LiveTvTunerStatus.LiveTv; } else { status = LiveTvTunerStatus.Available; }
+
                         tuners.Add(new LiveTvTunerInfo
                         {
                             Name = name,
@@ -229,11 +231,13 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
                     inside = true;
                     continue;
                 }
+
                 if (let == '>')
                 {
                     inside = false;
                     continue;
                 }
+
                 if (!inside)
                 {
                     buffer[bufferIndex] = let;
@@ -331,12 +335,19 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
         private class Channels
         {
             public string GuideNumber { get; set; }
+
             public string GuideName { get; set; }
+
             public string VideoCodec { get; set; }
+
             public string AudioCodec { get; set; }
+
             public string URL { get; set; }
+
             public bool Favorite { get; set; }
+
             public bool DRM { get; set; }
+
             public int HD { get; set; }
         }
 
@@ -657,13 +668,21 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts.HdHomerun
         public class DiscoverResponse
         {
             public string FriendlyName { get; set; }
+
             public string ModelNumber { get; set; }
+
             public string FirmwareName { get; set; }
+
             public string FirmwareVersion { get; set; }
+
             public string DeviceID { get; set; }
+
             public string DeviceAuth { get; set; }
+
             public string BaseURL { get; set; }
+
             public string LineupURL { get; set; }
+
             public int TunerCount { get; set; }
 
             public bool SupportsTranscoding

+ 3 - 0
Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs

@@ -58,12 +58,15 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
         protected virtual int EmptyReadLimit => 1000;
 
         public MediaSourceInfo OriginalMediaSource { get; set; }
+
         public MediaSourceInfo MediaSource { get; set; }
 
         public int ConsumerCount { get; set; }
 
         public string OriginalStreamId { get; set; }
+
         public bool EnableStreamSharing { get; set; }
+
         public string UniqueId { get; }
 
         public string TunerHostId { get; }

+ 1 - 0
Emby.Server.Implementations/Playlists/PlaylistManager.cs

@@ -401,6 +401,7 @@ namespace Emby.Server.Implementations.Playlists
                     {
                         entry.Duration = TimeSpan.FromTicks(child.RunTimeTicks.Value);
                     }
+
                     playlist.PlaylistEntries.Add(entry);
                 }
 

+ 5 - 0
Emby.Server.Implementations/ScheduledTasks/ScheduledTaskWorker.cs

@@ -143,12 +143,14 @@ namespace Emby.Server.Implementations.ScheduledTasks
                                 Logger.LogError(ex, "Error deserializing {File}", path);
                             }
                         }
+
                         _readFromFile = true;
                     }
                 }
 
                 return _lastExecutionResult;
             }
+
             private set
             {
                 _lastExecutionResult = value;
@@ -261,6 +263,7 @@ namespace Emby.Server.Implementations.ScheduledTasks
                 var triggers = InternalTriggers;
                 return triggers.Select(i => i.Item1).ToArray();
             }
+
             set
             {
                 if (value == null)
@@ -640,6 +643,7 @@ namespace Emby.Server.Implementations.ScheduledTasks
                         Logger.LogError(ex, "Error calling CancellationToken.Cancel();");
                     }
                 }
+
                 var task = _currentTask;
                 if (task != null)
                 {
@@ -675,6 +679,7 @@ namespace Emby.Server.Implementations.ScheduledTasks
                         Logger.LogError(ex, "Error calling CancellationToken.Dispose();");
                     }
                 }
+
                 if (wassRunning)
                 {
                     OnTaskCompleted(startTime, DateTime.UtcNow, TaskCompletionStatus.Aborted, null);

+ 1 - 0
Emby.Server.Implementations/Services/ServiceMethod.cs

@@ -9,6 +9,7 @@ namespace Emby.Server.Implementations.Services
         public string Id { get; set; }
 
         public ActionInvokerFn ServiceAction { get; set; }
+
         public MediaBrowser.Model.Services.IHasRequestFilter[] RequestFilters { get; set; }
 
         public static string Key(Type serviceType, string method, string requestDtoName)

+ 3 - 0
Emby.Server.Implementations/Services/ServicePath.cs

@@ -62,7 +62,9 @@ namespace Emby.Server.Implementations.Services
         public string Path => this.restPath;
 
         public string Summary { get; private set; }
+
         public string Description { get; private set; }
+
         public bool IsHidden { get; private set; }
 
         public static string[] GetPathPartsForMatching(string pathInfo)
@@ -159,6 +161,7 @@ namespace Emby.Server.Implementations.Services
                         this.isWildcard[i] = true;
                         variableName = variableName.Substring(0, variableName.Length - 1);
                     }
+
                     this.variablesNames[i] = variableName;
                     this.VariableArgsCount++;
                 }

+ 2 - 0
Emby.Server.Implementations/Services/StringMapTypeDeserializer.cs

@@ -22,7 +22,9 @@ namespace Emby.Server.Implementations.Services
             }
 
             public Action<object, object> PropertySetFn { get; private set; }
+
             public Func<string, object> PropertyParseStringFn { get; private set; }
+
             public Type PropertyType { get; private set; }
         }
 

+ 34 - 0
Emby.Server.Implementations/Services/SwaggerService.cs

@@ -18,13 +18,21 @@ namespace Emby.Server.Implementations.Services
     public class SwaggerSpec
     {
         public string swagger { get; set; }
+
         public string[] schemes { get; set; }
+
         public SwaggerInfo info { get; set; }
+
         public string host { get; set; }
+
         public string basePath { get; set; }
+
         public SwaggerTag[] tags { get; set; }
+
         public IDictionary<string, Dictionary<string, SwaggerMethod>> paths { get; set; }
+
         public Dictionary<string, SwaggerDefinition> definitions { get; set; }
+
         public SwaggerComponents components { get; set; }
     }
 
@@ -36,15 +44,20 @@ namespace Emby.Server.Implementations.Services
     public class SwaggerSecurityScheme
     {
         public string name { get; set; }
+
         public string type { get; set; }
+
         public string @in { get; set; }
     }
 
     public class SwaggerInfo
     {
         public string description { get; set; }
+
         public string version { get; set; }
+
         public string title { get; set; }
+
         public string termsOfService { get; set; }
 
         public SwaggerConcactInfo contact { get; set; }
@@ -53,36 +66,52 @@ namespace Emby.Server.Implementations.Services
     public class SwaggerConcactInfo
     {
         public string email { get; set; }
+
         public string name { get; set; }
+
         public string url { get; set; }
     }
 
     public class SwaggerTag
     {
         public string description { get; set; }
+
         public string name { get; set; }
     }
 
     public class SwaggerMethod
     {
         public string summary { get; set; }
+
         public string description { get; set; }
+
         public string[] tags { get; set; }
+
         public string operationId { get; set; }
+
         public string[] consumes { get; set; }
+
         public string[] produces { get; set; }
+
         public SwaggerParam[] parameters { get; set; }
+
         public Dictionary<string, SwaggerResponse> responses { get; set; }
+
         public Dictionary<string, string[]>[] security { get; set; }
     }
 
     public class SwaggerParam
     {
         public string @in { get; set; }
+
         public string name { get; set; }
+
         public string description { get; set; }
+
         public bool required { get; set; }
+
         public string type { get; set; }
+
         public string collectionFormat { get; set; }
     }
 
@@ -97,15 +126,20 @@ namespace Emby.Server.Implementations.Services
     public class SwaggerDefinition
     {
         public string type { get; set; }
+
         public Dictionary<string, SwaggerProperty> properties { get; set; }
     }
 
     public class SwaggerProperty
     {
         public string type { get; set; }
+
         public string format { get; set; }
+
         public string description { get; set; }
+
         public string[] @enum { get; set; }
+
         public string @default { get; set; }
     }
 

+ 1 - 0
Emby.Server.Implementations/Session/SessionWebSocketListener.cs

@@ -167,6 +167,7 @@ namespace Emby.Server.Implementations.Session
                     _logger.LogWarning("Multiple attempts to keep alive single WebSocket {0}", webSocket);
                     return;
                 }
+
                 webSocket.Closed += OnWebSocketClosed;
                 webSocket.LastKeepAliveDate = DateTime.UtcNow;
 

+ 1 - 0
Emby.Server.Implementations/Sorting/PremiereDateComparer.cs

@@ -44,6 +44,7 @@ namespace Emby.Server.Implementations.Sorting
                     // Don't blow up if the item has a bad ProductionYear, just return MinValue
                 }
             }
+
             return DateTime.MinValue;
         }
 

+ 1 - 0
Emby.Server.Implementations/TV/TVSeriesManager.cs

@@ -256,6 +256,7 @@ namespace Emby.Server.Implementations.TV
             {
                 items = items.Skip(query.StartIndex.Value);
             }
+
             if (query.Limit.HasValue)
             {
                 items = items.Take(query.Limit.Value);

+ 3 - 0
Jellyfin.Data/Entities/Artwork.cs

@@ -89,6 +89,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -127,6 +128,7 @@ namespace Jellyfin.Data.Entities
                 GetPath(ref value);
                 return (_Path = value);
             }
+
             set
             {
                 string oldValue = _Path;
@@ -163,6 +165,7 @@ namespace Jellyfin.Data.Entities
                 GetKind(ref value);
                 return (_Kind = value);
             }
+
             set
             {
                 Enums.ArtKind oldValue = _Kind;

+ 1 - 0
Jellyfin.Data/Entities/BookMetadata.cs

@@ -84,6 +84,7 @@ namespace Jellyfin.Data.Entities
                 GetISBN(ref value);
                 return (_ISBN = value);
             }
+
             set
             {
                 long? oldValue = _ISBN;

+ 5 - 0
Jellyfin.Data/Entities/Chapter.cs

@@ -86,6 +86,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -123,6 +124,7 @@ namespace Jellyfin.Data.Entities
                 GetName(ref value);
                 return (_Name = value);
             }
+
             set
             {
                 string oldValue = _Name;
@@ -163,6 +165,7 @@ namespace Jellyfin.Data.Entities
                 GetLanguage(ref value);
                 return (_Language = value);
             }
+
             set
             {
                 string oldValue = _Language;
@@ -199,6 +202,7 @@ namespace Jellyfin.Data.Entities
                 GetTimeStart(ref value);
                 return (_TimeStart = value);
             }
+
             set
             {
                 long oldValue = _TimeStart;
@@ -231,6 +235,7 @@ namespace Jellyfin.Data.Entities
                 GetTimeEnd(ref value);
                 return (_TimeEnd = value);
             }
+
             set
             {
                 long? oldValue = _TimeEnd;

+ 2 - 0
Jellyfin.Data/Entities/Collection.cs

@@ -49,6 +49,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -86,6 +87,7 @@ namespace Jellyfin.Data.Entities
                 GetName(ref value);
                 return (_Name = value);
             }
+
             set
             {
                 string oldValue = _Name;

+ 1 - 0
Jellyfin.Data/Entities/CollectionItem.cs

@@ -93,6 +93,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;

+ 1 - 0
Jellyfin.Data/Entities/Company.cs

@@ -101,6 +101,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;

+ 4 - 0
Jellyfin.Data/Entities/CompanyMetadata.cs

@@ -85,6 +85,7 @@ namespace Jellyfin.Data.Entities
                 GetDescription(ref value);
                 return (_Description = value);
             }
+
             set
             {
                 string oldValue = _Description;
@@ -122,6 +123,7 @@ namespace Jellyfin.Data.Entities
                 GetHeadquarters(ref value);
                 return (_Headquarters = value);
             }
+
             set
             {
                 string oldValue = _Headquarters;
@@ -159,6 +161,7 @@ namespace Jellyfin.Data.Entities
                 GetCountry(ref value);
                 return (_Country = value);
             }
+
             set
             {
                 string oldValue = _Country;
@@ -196,6 +199,7 @@ namespace Jellyfin.Data.Entities
                 GetHomepage(ref value);
                 return (_Homepage = value);
             }
+
             set
             {
                 string oldValue = _Homepage;

+ 1 - 0
Jellyfin.Data/Entities/Episode.cs

@@ -86,6 +86,7 @@ namespace Jellyfin.Data.Entities
                 GetEpisodeNumber(ref value);
                 return (_EpisodeNumber = value);
             }
+
             set
             {
                 int? oldValue = _EpisodeNumber;

+ 3 - 0
Jellyfin.Data/Entities/EpisodeMetadata.cs

@@ -85,6 +85,7 @@ namespace Jellyfin.Data.Entities
                 GetOutline(ref value);
                 return (_Outline = value);
             }
+
             set
             {
                 string oldValue = _Outline;
@@ -122,6 +123,7 @@ namespace Jellyfin.Data.Entities
                 GetPlot(ref value);
                 return (_Plot = value);
             }
+
             set
             {
                 string oldValue = _Plot;
@@ -159,6 +161,7 @@ namespace Jellyfin.Data.Entities
                 GetTagline(ref value);
                 return (_Tagline = value);
             }
+
             set
             {
                 string oldValue = _Tagline;

+ 2 - 0
Jellyfin.Data/Entities/Genre.cs

@@ -82,6 +82,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -120,6 +121,7 @@ namespace Jellyfin.Data.Entities
                 GetName(ref value);
                 return (_Name = value);
             }
+
             set
             {
                 string oldValue = _Name;

+ 2 - 0
Jellyfin.Data/Entities/Library.cs

@@ -77,6 +77,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -115,6 +116,7 @@ namespace Jellyfin.Data.Entities
                 GetName(ref value);
                 return (_Name = value);
             }
+
             set
             {
                 string oldValue = _Name;

+ 3 - 0
Jellyfin.Data/Entities/LibraryItem.cs

@@ -59,6 +59,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -96,6 +97,7 @@ namespace Jellyfin.Data.Entities
                 GetUrlId(ref value);
                 return (_UrlId = value);
             }
+
             set
             {
                 Guid oldValue = _UrlId;
@@ -132,6 +134,7 @@ namespace Jellyfin.Data.Entities
                 GetDateAdded(ref value);
                 return (_DateAdded = value);
             }
+
             internal set
             {
                 DateTime oldValue = _DateAdded;

+ 3 - 0
Jellyfin.Data/Entities/LibraryRoot.cs

@@ -77,6 +77,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -116,6 +117,7 @@ namespace Jellyfin.Data.Entities
                 GetPath(ref value);
                 return (_Path = value);
             }
+
             set
             {
                 string oldValue = _Path;
@@ -154,6 +156,7 @@ namespace Jellyfin.Data.Entities
                 GetNetworkPath(ref value);
                 return (_NetworkPath = value);
             }
+
             set
             {
                 string oldValue = _NetworkPath;

+ 3 - 0
Jellyfin.Data/Entities/MediaFile.cs

@@ -90,6 +90,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -129,6 +130,7 @@ namespace Jellyfin.Data.Entities
                 GetPath(ref value);
                 return (_Path = value);
             }
+
             set
             {
                 string oldValue = _Path;
@@ -165,6 +167,7 @@ namespace Jellyfin.Data.Entities
                 GetKind(ref value);
                 return (_Kind = value);
             }
+
             set
             {
                 Enums.MediaFileKind oldValue = _Kind;

+ 2 - 0
Jellyfin.Data/Entities/MediaFileStream.cs

@@ -81,6 +81,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -117,6 +118,7 @@ namespace Jellyfin.Data.Entities
                 GetStreamNumber(ref value);
                 return (_StreamNumber = value);
             }
+
             set
             {
                 int oldValue = _StreamNumber;

+ 8 - 0
Jellyfin.Data/Entities/Metadata.cs

@@ -76,6 +76,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -115,6 +116,7 @@ namespace Jellyfin.Data.Entities
                 GetTitle(ref value);
                 return (_Title = value);
             }
+
             set
             {
                 string oldValue = _Title;
@@ -152,6 +154,7 @@ namespace Jellyfin.Data.Entities
                 GetOriginalTitle(ref value);
                 return (_OriginalTitle = value);
             }
+
             set
             {
                 string oldValue = _OriginalTitle;
@@ -189,6 +192,7 @@ namespace Jellyfin.Data.Entities
                 GetSortTitle(ref value);
                 return (_SortTitle = value);
             }
+
             set
             {
                 string oldValue = _SortTitle;
@@ -229,6 +233,7 @@ namespace Jellyfin.Data.Entities
                 GetLanguage(ref value);
                 return (_Language = value);
             }
+
             set
             {
                 string oldValue = _Language;
@@ -261,6 +266,7 @@ namespace Jellyfin.Data.Entities
                 GetReleaseDate(ref value);
                 return (_ReleaseDate = value);
             }
+
             set
             {
                 DateTimeOffset? oldValue = _ReleaseDate;
@@ -297,6 +303,7 @@ namespace Jellyfin.Data.Entities
                 GetDateAdded(ref value);
                 return (_DateAdded = value);
             }
+
             internal set
             {
                 DateTime oldValue = _DateAdded;
@@ -333,6 +340,7 @@ namespace Jellyfin.Data.Entities
                 GetDateModified(ref value);
                 return (_DateModified = value);
             }
+
             internal set
             {
                 DateTime oldValue = _DateModified;

+ 2 - 0
Jellyfin.Data/Entities/MetadataProvider.cs

@@ -77,6 +77,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -115,6 +116,7 @@ namespace Jellyfin.Data.Entities
                 GetName(ref value);
                 return (_Name = value);
             }
+
             set
             {
                 string oldValue = _Name;

+ 2 - 0
Jellyfin.Data/Entities/MetadataProviderId.cs

@@ -103,6 +103,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -141,6 +142,7 @@ namespace Jellyfin.Data.Entities
                 GetProviderId(ref value);
                 return (_ProviderId = value);
             }
+
             set
             {
                 string oldValue = _ProviderId;

+ 4 - 0
Jellyfin.Data/Entities/MovieMetadata.cs

@@ -90,6 +90,7 @@ namespace Jellyfin.Data.Entities
                 GetOutline(ref value);
                 return (_Outline = value);
             }
+
             set
             {
                 string oldValue = _Outline;
@@ -127,6 +128,7 @@ namespace Jellyfin.Data.Entities
                 GetPlot(ref value);
                 return (_Plot = value);
             }
+
             set
             {
                 string oldValue = _Plot;
@@ -164,6 +166,7 @@ namespace Jellyfin.Data.Entities
                 GetTagline(ref value);
                 return (_Tagline = value);
             }
+
             set
             {
                 string oldValue = _Tagline;
@@ -201,6 +204,7 @@ namespace Jellyfin.Data.Entities
                 GetCountry(ref value);
                 return (_Country = value);
             }
+
             set
             {
                 string oldValue = _Country;

+ 3 - 0
Jellyfin.Data/Entities/MusicAlbumMetadata.cs

@@ -90,6 +90,7 @@ namespace Jellyfin.Data.Entities
                 GetBarcode(ref value);
                 return (_Barcode = value);
             }
+
             set
             {
                 string oldValue = _Barcode;
@@ -127,6 +128,7 @@ namespace Jellyfin.Data.Entities
                 GetLabelNumber(ref value);
                 return (_LabelNumber = value);
             }
+
             set
             {
                 string oldValue = _LabelNumber;
@@ -164,6 +166,7 @@ namespace Jellyfin.Data.Entities
                 GetCountry(ref value);
                 return (_Country = value);
             }
+
             set
             {
                 string oldValue = _Country;

+ 6 - 0
Jellyfin.Data/Entities/Person.cs

@@ -85,6 +85,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -121,6 +122,7 @@ namespace Jellyfin.Data.Entities
                 GetUrlId(ref value);
                 return (_UrlId = value);
             }
+
             set
             {
                 Guid oldValue = _UrlId;
@@ -159,6 +161,7 @@ namespace Jellyfin.Data.Entities
                 GetName(ref value);
                 return (_Name = value);
             }
+
             set
             {
                 string oldValue = _Name;
@@ -196,6 +199,7 @@ namespace Jellyfin.Data.Entities
                 GetSourceId(ref value);
                 return (_SourceId = value);
             }
+
             set
             {
                 string oldValue = _SourceId;
@@ -232,6 +236,7 @@ namespace Jellyfin.Data.Entities
                 GetDateAdded(ref value);
                 return (_DateAdded = value);
             }
+
             internal set
             {
                 DateTime oldValue = _DateAdded;
@@ -268,6 +273,7 @@ namespace Jellyfin.Data.Entities
                 GetDateModified(ref value);
                 return (_DateModified = value);
             }
+
             internal set
             {
                 DateTime oldValue = _DateModified;

+ 3 - 0
Jellyfin.Data/Entities/PersonRole.cs

@@ -91,6 +91,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -128,6 +129,7 @@ namespace Jellyfin.Data.Entities
                 GetRole(ref value);
                 return (_Role = value);
             }
+
             set
             {
                 string oldValue = _Role;
@@ -164,6 +166,7 @@ namespace Jellyfin.Data.Entities
                 GetType(ref value);
                 return (_Type = value);
             }
+
             set
             {
                 Enums.PersonRoleType oldValue = _Type;

+ 3 - 0
Jellyfin.Data/Entities/Rating.cs

@@ -81,6 +81,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -117,6 +118,7 @@ namespace Jellyfin.Data.Entities
                 GetValue(ref value);
                 return (_Value = value);
             }
+
             set
             {
                 double oldValue = _Value;
@@ -149,6 +151,7 @@ namespace Jellyfin.Data.Entities
                 GetVotes(ref value);
                 return (_Votes = value);
             }
+
             set
             {
                 int? oldValue = _Votes;

+ 4 - 0
Jellyfin.Data/Entities/RatingSource.cs

@@ -88,6 +88,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -125,6 +126,7 @@ namespace Jellyfin.Data.Entities
                 GetName(ref value);
                 return (_Name = value);
             }
+
             set
             {
                 string oldValue = _Name;
@@ -161,6 +163,7 @@ namespace Jellyfin.Data.Entities
                 GetMaximumValue(ref value);
                 return (_MaximumValue = value);
             }
+
             set
             {
                 double oldValue = _MaximumValue;
@@ -197,6 +200,7 @@ namespace Jellyfin.Data.Entities
                 GetMinimumValue(ref value);
                 return (_MinimumValue = value);
             }
+
             set
             {
                 double oldValue = _MinimumValue;

+ 2 - 0
Jellyfin.Data/Entities/Release.cs

@@ -113,6 +113,7 @@ namespace Jellyfin.Data.Entities
                 GetId(ref value);
                 return (_Id = value);
             }
+
             protected set
             {
                 int oldValue = _Id;
@@ -151,6 +152,7 @@ namespace Jellyfin.Data.Entities
                 GetName(ref value);
                 return (_Name = value);
             }
+
             set
             {
                 string oldValue = _Name;

+ 1 - 0
Jellyfin.Data/Entities/Season.cs

@@ -86,6 +86,7 @@ namespace Jellyfin.Data.Entities
                 GetSeasonNumber(ref value);
                 return (_SeasonNumber = value);
             }
+
             set
             {
                 int? oldValue = _SeasonNumber;

+ 1 - 0
Jellyfin.Data/Entities/SeasonMetadata.cs

@@ -86,6 +86,7 @@ namespace Jellyfin.Data.Entities
                 GetOutline(ref value);
                 return (_Outline = value);
             }
+
             set
             {
                 string oldValue = _Outline;

+ 3 - 0
Jellyfin.Data/Entities/Series.cs

@@ -67,6 +67,7 @@ namespace Jellyfin.Data.Entities
                 GetAirsDayOfWeek(ref value);
                 return (_AirsDayOfWeek = value);
             }
+
             set
             {
                 DayOfWeek? oldValue = _AirsDayOfWeek;
@@ -102,6 +103,7 @@ namespace Jellyfin.Data.Entities
                 GetAirsTime(ref value);
                 return (_AirsTime = value);
             }
+
             set
             {
                 DateTimeOffset? oldValue = _AirsTime;
@@ -134,6 +136,7 @@ namespace Jellyfin.Data.Entities
                 GetFirstAired(ref value);
                 return (_FirstAired = value);
             }
+
             set
             {
                 DateTimeOffset? oldValue = _FirstAired;

+ 4 - 0
Jellyfin.Data/Entities/SeriesMetadata.cs

@@ -90,6 +90,7 @@ namespace Jellyfin.Data.Entities
                 GetOutline(ref value);
                 return (_Outline = value);
             }
+
             set
             {
                 string oldValue = _Outline;
@@ -127,6 +128,7 @@ namespace Jellyfin.Data.Entities
                 GetPlot(ref value);
                 return (_Plot = value);
             }
+
             set
             {
                 string oldValue = _Plot;
@@ -164,6 +166,7 @@ namespace Jellyfin.Data.Entities
                 GetTagline(ref value);
                 return (_Tagline = value);
             }
+
             set
             {
                 string oldValue = _Tagline;
@@ -201,6 +204,7 @@ namespace Jellyfin.Data.Entities
                 GetCountry(ref value);
                 return (_Country = value);
             }
+
             set
             {
                 string oldValue = _Country;

+ 1 - 0
Jellyfin.Data/Entities/Track.cs

@@ -86,6 +86,7 @@ namespace Jellyfin.Data.Entities
                 GetTrackNumber(ref value);
                 return (_TrackNumber = value);
             }
+
             set
             {
                 int? oldValue = _TrackNumber;

+ 39 - 0
Jellyfin.Server.Implementations/JellyfinDb.cs

@@ -34,37 +34,69 @@ namespace Jellyfin.Server.Implementations
         public virtual DbSet<Preference> Preferences { get; set; }
 
         public virtual DbSet<User> Users { get; set; }
+
         /*public virtual DbSet<Artwork> Artwork { get; set; }
+
         public virtual DbSet<Book> Books { get; set; }
+
         public virtual DbSet<BookMetadata> BookMetadata { get; set; }
+
         public virtual DbSet<Chapter> Chapters { get; set; }
+
         public virtual DbSet<Collection> Collections { get; set; }
+
         public virtual DbSet<CollectionItem> CollectionItems { get; set; }
+
         public virtual DbSet<Company> Companies { get; set; }
+
         public virtual DbSet<CompanyMetadata> CompanyMetadata { get; set; }
+
         public virtual DbSet<CustomItem> CustomItems { get; set; }
+
         public virtual DbSet<CustomItemMetadata> CustomItemMetadata { get; set; }
+
         public virtual DbSet<Episode> Episodes { get; set; }
+
         public virtual DbSet<EpisodeMetadata> EpisodeMetadata { get; set; }
+
         public virtual DbSet<Genre> Genres { get; set; }
+
         public virtual DbSet<Group> Groups { get; set; }
+
         public virtual DbSet<Library> Libraries { get; set; }
+
         public virtual DbSet<LibraryItem> LibraryItems { get; set; }
+
         public virtual DbSet<LibraryRoot> LibraryRoot { get; set; }
+
         public virtual DbSet<MediaFile> MediaFiles { get; set; }
+
         public virtual DbSet<MediaFileStream> MediaFileStream { get; set; }
+
         public virtual DbSet<Metadata> Metadata { get; set; }
+
         public virtual DbSet<MetadataProvider> MetadataProviders { get; set; }
+
         public virtual DbSet<MetadataProviderId> MetadataProviderIds { get; set; }
+
         public virtual DbSet<Movie> Movies { get; set; }
+
         public virtual DbSet<MovieMetadata> MovieMetadata { get; set; }
+
         public virtual DbSet<MusicAlbum> MusicAlbums { get; set; }
+
         public virtual DbSet<MusicAlbumMetadata> MusicAlbumMetadata { get; set; }
+
         public virtual DbSet<Person> People { get; set; }
+
         public virtual DbSet<PersonRole> PersonRoles { get; set; }
+
         public virtual DbSet<Photo> Photo { get; set; }
+
         public virtual DbSet<PhotoMetadata> PhotoMetadata { get; set; }
+
         public virtual DbSet<ProviderMapping> ProviderMappings { get; set; }
+
         public virtual DbSet<Rating> Ratings { get; set; }
 
         /// <summary>
@@ -72,12 +104,19 @@ namespace Jellyfin.Server.Implementations
         /// store review ratings, not age ratings
         /// </summary>
         public virtual DbSet<RatingSource> RatingSources { get; set; }
+
         public virtual DbSet<Release> Releases { get; set; }
+
         public virtual DbSet<Season> Seasons { get; set; }
+
         public virtual DbSet<SeasonMetadata> SeasonMetadata { get; set; }
+
         public virtual DbSet<Series> Series { get; set; }
+
         public virtual DbSet<SeriesMetadata> SeriesMetadata { get; set; }
+
         public virtual DbSet<Track> Tracks { get; set; }
+
         public virtual DbSet<TrackMetadata> TrackMetadata { get; set; }*/
 
         /// <inheritdoc/>

+ 1 - 0
MediaBrowser.Api/EnvironmentService.cs

@@ -50,6 +50,7 @@ namespace MediaBrowser.Api
         public string Path { get; set; }
 
         public bool ValidateWriteable { get; set; }
+
         public bool? IsFile { get; set; }
     }
 

+ 6 - 0
MediaBrowser.Api/FilterService.cs

@@ -73,11 +73,17 @@ namespace MediaBrowser.Api
         }
 
         public bool? IsAiring { get; set; }
+
         public bool? IsMovie { get; set; }
+
         public bool? IsSports { get; set; }
+
         public bool? IsKids { get; set; }
+
         public bool? IsNews { get; set; }
+
         public bool? IsSeries { get; set; }
+
         public bool? Recursive { get; set; }
     }
 

+ 1 - 0
MediaBrowser.Api/IHasDtoOptions.cs

@@ -3,6 +3,7 @@ namespace MediaBrowser.Api
     public interface IHasDtoOptions : IHasItemFields
     {
         bool? EnableImages { get; set; }
+
         bool? EnableUserData { get; set; }
 
         int? ImageTypeLimit { get; set; }

+ 11 - 0
MediaBrowser.Api/Library/LibraryService.cs

@@ -285,29 +285,38 @@ namespace MediaBrowser.Api.Library
     public class GetLibraryOptionsInfo : IReturn<LibraryOptionsResult>
     {
         public string LibraryContentType { get; set; }
+
         public bool IsNewLibrary { get; set; }
     }
 
     public class LibraryOptionInfo
     {
         public string Name { get; set; }
+
         public bool DefaultEnabled { get; set; }
     }
 
     public class LibraryOptionsResult
     {
         public LibraryOptionInfo[] MetadataSavers { get; set; }
+
         public LibraryOptionInfo[] MetadataReaders { get; set; }
+
         public LibraryOptionInfo[] SubtitleFetchers { get; set; }
+
         public LibraryTypeOptions[] TypeOptions { get; set; }
     }
 
     public class LibraryTypeOptions
     {
         public string Type { get; set; }
+
         public LibraryOptionInfo[] MetadataFetchers { get; set; }
+
         public LibraryOptionInfo[] ImageFetchers { get; set; }
+
         public ImageType[] SupportedImageTypes { get; set; }
+
         public ImageOption[] DefaultImageOptions { get; set; }
     }
 
@@ -1036,6 +1045,7 @@ namespace MediaBrowser.Api.Library
                 {
                     break;
                 }
+
                 item = parent;
             }
 
@@ -1093,6 +1103,7 @@ namespace MediaBrowser.Api.Library
                 {
                     break;
                 }
+
                 item = parent;
             }
 

+ 15 - 0
MediaBrowser.Api/LiveTv/LiveTvService.cs

@@ -200,10 +200,15 @@ namespace MediaBrowser.Api.LiveTv
         public bool? EnableUserData { get; set; }
 
         public bool? IsMovie { get; set; }
+
         public bool? IsSeries { get; set; }
+
         public bool? IsKids { get; set; }
+
         public bool? IsSports { get; set; }
+
         public bool? IsNews { get; set; }
+
         public bool? IsLibraryItem { get; set; }
 
         public GetRecordings()
@@ -348,6 +353,7 @@ namespace MediaBrowser.Api.LiveTv
 
         [ApiMember(Name = "HasAired", Description = "Optional. Filter by programs that have completed airing, or not.", IsRequired = false, DataType = "bool", ParameterType = "query", Verb = "GET")]
         public bool? HasAired { get; set; }
+
         public bool? IsAiring { get; set; }
 
         [ApiMember(Name = "MaxStartDate", Description = "Optional. The maximum premiere date. Format = ISO", IsRequired = false, DataType = "string", ParameterType = "query", Verb = "GET,POST")]
@@ -407,6 +413,7 @@ namespace MediaBrowser.Api.LiveTv
         public bool? EnableUserData { get; set; }
 
         public string SeriesTimerId { get; set; }
+
         public Guid LibrarySeriesId { get; set; }
 
         /// <summary>
@@ -601,7 +608,9 @@ namespace MediaBrowser.Api.LiveTv
     public class AddListingProvider : ListingsProviderInfo, IReturn<ListingsProviderInfo>
     {
         public bool ValidateLogin { get; set; }
+
         public bool ValidateListings { get; set; }
+
         public string Pw { get; set; }
     }
 
@@ -650,15 +659,20 @@ namespace MediaBrowser.Api.LiveTv
     {
         [ApiMember(Name = "Id", Description = "Provider id", IsRequired = true, DataType = "string", ParameterType = "query")]
         public string ProviderId { get; set; }
+
         public string TunerChannelId { get; set; }
+
         public string ProviderChannelId { get; set; }
     }
 
     public class ChannelMappingOptions
     {
         public List<TunerChannelMapping> TunerChannels { get; set; }
+
         public List<NameIdPair> ProviderChannels { get; set; }
+
         public NameValuePair[] Mappings { get; set; }
+
         public string ProviderName { get; set; }
     }
 
@@ -666,6 +680,7 @@ namespace MediaBrowser.Api.LiveTv
     public class GetLiveStreamFile
     {
         public string Id { get; set; }
+
         public string Container { get; set; }
     }
 

+ 4 - 0
MediaBrowser.Api/Playback/BaseStreamingService.cs

@@ -303,6 +303,7 @@ namespace MediaBrowser.Api.Playback
             {
                 StartThrottler(state, transcodingJob);
             }
+
             Logger.LogDebug("StartFfMpeg() finished successfully");
 
             return transcodingJob;
@@ -608,6 +609,7 @@ namespace MediaBrowser.Api.Playback
             {
                 throw new ArgumentException("Invalid timeseek header");
             }
+
             int index = value.IndexOf('-');
             value = index == -1
                 ? value.Substring(Npt.Length)
@@ -639,8 +641,10 @@ namespace MediaBrowser.Api.Playback
                 {
                     throw new ArgumentException("Invalid timeseek header");
                 }
+
                 timeFactor /= 60;
             }
+
             return TimeSpan.FromSeconds(secondsSum).Ticks;
         }
 

+ 1 - 0
MediaBrowser.Api/Playback/Hls/BaseHlsService.cs

@@ -146,6 +146,7 @@ namespace MediaBrowser.Api.Playback.Hls
                 {
                     ApiEntryPoint.Instance.OnTranscodeEndRequest(job);
                 }
+
                 return ResultFactory.GetResult(GetLivePlaylistText(playlist, state.SegmentLength), MimeTypes.GetMimeType("playlist.m3u8"), new Dictionary<string, string>());
             }
 

+ 2 - 0
MediaBrowser.Api/Playback/Hls/DynamicHlsService.cs

@@ -234,6 +234,7 @@ namespace MediaBrowser.Api.Playback.Hls
                         Logger.LogDebug("Starting transcoding because segmentGap is {0} and max allowed gap is {1}. requestedIndex={2}", requestedIndex - currentTranscodingIndex.Value, segmentGapRequiringTranscodingChange, requestedIndex);
                         startTranscoding = true;
                     }
+
                     if (startTranscoding)
                     {
                         // If the playlist doesn't already exist, startup ffmpeg
@@ -518,6 +519,7 @@ namespace MediaBrowser.Api.Playback.Hls
                 {
                     Logger.LogDebug("serving {0} as it's on disk and transcoding stopped", segmentPath);
                 }
+
                 cancellationToken.ThrowIfCancellationRequested();
             }
             else

+ 2 - 0
MediaBrowser.Api/Playback/MediaInfoService.cs

@@ -551,10 +551,12 @@ namespace MediaBrowser.Api.Playback
                             {
                                 mediaSource.TranscodingUrl += "&allowVideoStreamCopy=false";
                             }
+
                             if (!allowAudioStreamCopy)
                             {
                                 mediaSource.TranscodingUrl += "&allowAudioStreamCopy=false";
                             }
+
                             mediaSource.TranscodingContainer = streamInfo.Container;
                             mediaSource.TranscodingSubProtocol = streamInfo.SubProtocol;
                         }

+ 6 - 0
MediaBrowser.Api/Playback/Progressive/BaseProgressiveStreamingService.cs

@@ -88,14 +88,17 @@ namespace MediaBrowser.Api.Playback.Progressive
                 {
                     return ".ts";
                 }
+
                 if (string.Equals(videoCodec, "theora", StringComparison.OrdinalIgnoreCase))
                 {
                     return ".ogv";
                 }
+
                 if (string.Equals(videoCodec, "vpx", StringComparison.OrdinalIgnoreCase))
                 {
                     return ".webm";
                 }
+
                 if (string.Equals(videoCodec, "wmv", StringComparison.OrdinalIgnoreCase))
                 {
                     return ".asf";
@@ -111,14 +114,17 @@ namespace MediaBrowser.Api.Playback.Progressive
                 {
                     return ".aac";
                 }
+
                 if (string.Equals("mp3", audioCodec, StringComparison.OrdinalIgnoreCase))
                 {
                     return ".mp3";
                 }
+
                 if (string.Equals("vorbis", audioCodec, StringComparison.OrdinalIgnoreCase))
                 {
                     return ".ogg";
                 }
+
                 if (string.Equals("wma", audioCodec, StringComparison.OrdinalIgnoreCase))
                 {
                     return ".wma";

+ 2 - 0
MediaBrowser.Api/Playback/Progressive/ProgressiveStreamWriter.cs

@@ -23,6 +23,7 @@ namespace MediaBrowser.Api.Playback.Progressive
 
         private long _bytesWritten = 0;
         public long StartPosition { get; set; }
+
         public bool AllowEndOfFile = true;
 
         private readonly IDirectStreamProvider _directStreamProvider;
@@ -105,6 +106,7 @@ namespace MediaBrowser.Api.Playback.Progressive
                             {
                                 eofCount++;
                             }
+
                             await Task.Delay(100, cancellationToken).ConfigureAwait(false);
                         }
                         else

+ 4 - 0
MediaBrowser.Api/Playback/StreamRequest.cs

@@ -12,11 +12,15 @@ namespace MediaBrowser.Api.Playback
         public string DeviceProfileId { get; set; }
 
         public string Params { get; set; }
+
         public string PlaySessionId { get; set; }
+
         public string Tag { get; set; }
+
         public string SegmentContainer { get; set; }
 
         public int? SegmentLength { get; set; }
+
         public int? MinSegments { get; set; }
     }
 

+ 20 - 0
MediaBrowser.Api/Playback/UniversalAudioService.cs

@@ -37,10 +37,13 @@ namespace MediaBrowser.Api.Playback
         public string DeviceId { get; set; }
 
         public Guid UserId { get; set; }
+
         public string AudioCodec { get; set; }
+
         public string Container { get; set; }
 
         public int? MaxAudioChannels { get; set; }
+
         public int? TranscodingAudioChannels { get; set; }
 
         public long? MaxStreamingBitrate { get; set; }
@@ -49,12 +52,17 @@ namespace MediaBrowser.Api.Playback
         public long? StartTimeTicks { get; set; }
 
         public string TranscodingContainer { get; set; }
+
         public string TranscodingProtocol { get; set; }
+
         public int? MaxAudioSampleRate { get; set; }
+
         public int? MaxAudioBitDepth { get; set; }
 
         public bool EnableRedirection { get; set; }
+
         public bool EnableRemoteMedia { get; set; }
+
         public bool BreakOnNonKeyFrames { get; set; }
 
         public BaseUniversalRequest()
@@ -114,16 +122,27 @@ namespace MediaBrowser.Api.Playback
         }
 
         protected IHttpClient HttpClient { get; private set; }
+
         protected IUserManager UserManager { get; private set; }
+
         protected ILibraryManager LibraryManager { get; private set; }
+
         protected IIsoManager IsoManager { get; private set; }
+
         protected IMediaEncoder MediaEncoder { get; private set; }
+
         protected IFileSystem FileSystem { get; private set; }
+
         protected IDlnaManager DlnaManager { get; private set; }
+
         protected IDeviceManager DeviceManager { get; private set; }
+
         protected IMediaSourceManager MediaSourceManager { get; private set; }
+
         protected IJsonSerializer JsonSerializer { get; private set; }
+
         protected IAuthorizationContext AuthorizationContext { get; private set; }
+
         protected INetworkManager NetworkManager { get; private set; }
 
         public Task<object> Get(GetUniversalAudioStream request)
@@ -328,6 +347,7 @@ namespace MediaBrowser.Api.Playback
                 {
                     return await service.Head(newRequest).ConfigureAwait(false);
                 }
+
                 return await service.Get(newRequest).ConfigureAwait(false);
             }
             else

+ 9 - 0
MediaBrowser.Api/PluginService.cs

@@ -115,24 +115,33 @@ namespace MediaBrowser.Api
     public class RegistrationInfo
     {
         public string Name { get; set; }
+
         public DateTime ExpirationDate { get; set; }
+
         public bool IsTrial { get; set; }
+
         public bool IsRegistered { get; set; }
     }
 
     public class MBRegistrationRecord
     {
         public DateTime ExpirationDate { get; set; }
+
         public bool IsRegistered { get; set; }
+
         public bool RegChecked { get; set; }
+
         public bool RegError { get; set; }
+
         public bool TrialVersion { get; set; }
+
         public bool IsValid { get; set; }
     }
 
     public class PluginSecurityInfo
     {
         public string SupporterKey { get; set; }
+
         public bool IsMBSupporter { get; set; }
     }
     /// <summary>

+ 4 - 0
MediaBrowser.Api/SimilarItemsHelper.cs

@@ -179,18 +179,22 @@ namespace MediaBrowser.Api
                 {
                     return 5;
                 }
+
                 if (string.Equals(i.Type, PersonType.Actor, StringComparison.OrdinalIgnoreCase) || string.Equals(i.Role, PersonType.Actor, StringComparison.OrdinalIgnoreCase))
                 {
                     return 3;
                 }
+
                 if (string.Equals(i.Type, PersonType.Composer, StringComparison.OrdinalIgnoreCase) || string.Equals(i.Role, PersonType.Composer, StringComparison.OrdinalIgnoreCase))
                 {
                     return 3;
                 }
+
                 if (string.Equals(i.Type, PersonType.GuestStar, StringComparison.OrdinalIgnoreCase) || string.Equals(i.Role, PersonType.GuestStar, StringComparison.OrdinalIgnoreCase))
                 {
                     return 3;
                 }
+
                 if (string.Equals(i.Type, PersonType.Writer, StringComparison.OrdinalIgnoreCase) || string.Equals(i.Role, PersonType.Writer, StringComparison.OrdinalIgnoreCase))
                 {
                     return 2;

+ 2 - 0
MediaBrowser.Api/Subtitles/SubtitleService.cs

@@ -97,6 +97,7 @@ namespace MediaBrowser.Api.Subtitles
 
         [ApiMember(Name = "CopyTimestamps", Description = "CopyTimestamps", IsRequired = false, DataType = "bool", ParameterType = "query", Verb = "GET")]
         public bool CopyTimestamps { get; set; }
+
         public bool AddVttTimeMap { get; set; }
     }
 
@@ -214,6 +215,7 @@ namespace MediaBrowser.Api.Subtitles
             {
                 request.Format = "json";
             }
+
             if (string.IsNullOrEmpty(request.Format))
             {
                 var item = (Video)_libraryManager.GetItemById(request.Id);

+ 5 - 0
MediaBrowser.Api/SuggestionsService.cs

@@ -18,10 +18,15 @@ namespace MediaBrowser.Api
     public class GetSuggestedItems : IReturn<QueryResult<BaseItemDto>>
     {
         public string MediaType { get; set; }
+
         public string Type { get; set; }
+
         public Guid UserId { get; set; }
+
         public bool EnableTotalRecordCount { get; set; }
+
         public int? StartIndex { get; set; }
+
         public int? Limit { get; set; }
 
         public string[] GetMediaTypes()

+ 8 - 0
MediaBrowser.Api/TranscodingJob.cs

@@ -32,6 +32,7 @@ namespace MediaBrowser.Api
         /// </summary>
         /// <value>The path.</value>
         public MediaSourceInfo MediaSource { get; set; }
+
         public string Path { get; set; }
         /// <summary>
         /// Gets or sets the type.
@@ -43,6 +44,7 @@ namespace MediaBrowser.Api
         /// </summary>
         /// <value>The process.</value>
         public Process Process { get; set; }
+
         public ILogger Logger { get; private set; }
         /// <summary>
         /// Gets or sets the active request count.
@@ -62,18 +64,23 @@ namespace MediaBrowser.Api
         public object ProcessLock = new object();
 
         public bool HasExited { get; set; }
+
         public bool IsUserPaused { get; set; }
 
         public string Id { get; set; }
 
         public float? Framerate { get; set; }
+
         public double? CompletionPercentage { get; set; }
 
         public long? BytesDownloaded { get; set; }
+
         public long? BytesTranscoded { get; set; }
+
         public int? BitRate { get; set; }
 
         public long? TranscodingPositionTicks { get; set; }
+
         public long? DownloadPositionTicks { get; set; }
 
         public TranscodingThrottler TranscodingThrottler { get; set; }
@@ -81,6 +88,7 @@ namespace MediaBrowser.Api
         private readonly object _timerLock = new object();
 
         public DateTime LastPingDate { get; set; }
+
         public int PingTimeout { get; set; }
 
         public TranscodingJob(ILogger logger)

+ 1 - 0
MediaBrowser.Api/TvShowsService.cs

@@ -73,6 +73,7 @@ namespace MediaBrowser.Api
 
         [ApiMember(Name = "EnableUserData", Description = "Optional, include user data", IsRequired = false, DataType = "boolean", ParameterType = "query", Verb = "GET")]
         public bool? EnableUserData { get; set; }
+
         public bool EnableTotalRecordCount { get; set; }
 
         public GetNextUpEpisodes()

+ 1 - 0
MediaBrowser.Api/UserLibrary/BaseItemsByNameService.cs

@@ -210,6 +210,7 @@ namespace MediaBrowser.Api.UserLibrary
                 {
                     SetItemCounts(dto, i.Item2);
                 }
+
                 return dto;
             });
 

Неке датотеке нису приказане због велике количине промена