The Free Software Media System - Server Backend & API
Enable TreatWarningsAsErrors for some projects
Bond_0095a8e972952e4
diff --git a/Emby.Naming/Audio/AlbumParser.cs b/Emby.Naming/Audio/AlbumParser.csindex e8d7655525..4975b8e19d 100644--- a/Emby.Naming/Audio/AlbumParser.cs+++ b/Emby.Naming/Audio/AlbumParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Globalization;using System.IO;diff --git a/Emby.Naming/Audio/AudioFileParser.cs b/Emby.Naming/Audio/AudioFileParser.csindex 609eb779ad..9f21e93dc4 100644--- a/Emby.Naming/Audio/AudioFileParser.cs+++ b/Emby.Naming/Audio/AudioFileParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.IO;using System.Linq;diff --git a/Emby.Naming/Audio/MultiPartResult.cs b/Emby.Naming/Audio/MultiPartResult.csindex 00e4a9eb2e..8f68d97fa8 100644--- a/Emby.Naming/Audio/MultiPartResult.cs+++ b/Emby.Naming/Audio/MultiPartResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Audio{public class MultiPartResultdiff --git a/Emby.Naming/AudioBook/AudioBookFilePathParser.cs b/Emby.Naming/AudioBook/AudioBookFilePathParser.csindex ea7f06c8cb..8dc2e1b97c 100644--- a/Emby.Naming/AudioBook/AudioBookFilePathParser.cs+++ b/Emby.Naming/AudioBook/AudioBookFilePathParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Globalization;using System.IO;diff --git a/Emby.Naming/AudioBook/AudioBookFilePathParserResult.cs b/Emby.Naming/AudioBook/AudioBookFilePathParserResult.csindex f845e82435..68d6ca4d46 100644--- a/Emby.Naming/AudioBook/AudioBookFilePathParserResult.cs+++ b/Emby.Naming/AudioBook/AudioBookFilePathParserResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.AudioBook{public class AudioBookFilePathParserResultdiff --git a/Emby.Naming/AudioBook/AudioBookInfo.cs b/Emby.Naming/AudioBook/AudioBookInfo.csindex d53f53c528..b0b5bd881f 100644--- a/Emby.Naming/AudioBook/AudioBookInfo.cs+++ b/Emby.Naming/AudioBook/AudioBookInfo.cs@@ -7,6 +7,9 @@ namespace Emby.Naming.AudioBook/// </summary>public class AudioBookInfo{+ /// <summary>+ /// Initializes a new instance of the <see cref="AudioBookInfo" /> class.+ /// </summary>public AudioBookInfo(){Files = new List<AudioBookFileInfo>();diff --git a/Emby.Naming/AudioBook/AudioBookListResolver.cs b/Emby.Naming/AudioBook/AudioBookListResolver.csindex 414ef11830..97f3592857 100644--- a/Emby.Naming/AudioBook/AudioBookListResolver.cs+++ b/Emby.Naming/AudioBook/AudioBookListResolver.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System.Collections.Generic;using System.Linq;using Emby.Naming.Common;diff --git a/Emby.Naming/AudioBook/AudioBookResolver.cs b/Emby.Naming/AudioBook/AudioBookResolver.csindex 4a2b516d0e..0b0d2035e7 100644--- a/Emby.Naming/AudioBook/AudioBookResolver.cs+++ b/Emby.Naming/AudioBook/AudioBookResolver.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.IO;using System.Linq;diff --git a/Emby.Naming/Common/EpisodeExpression.cs b/Emby.Naming/Common/EpisodeExpression.csindex 136d8189dd..30a74fb657 100644--- a/Emby.Naming/Common/EpisodeExpression.cs+++ b/Emby.Naming/Common/EpisodeExpression.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Text.RegularExpressions;diff --git a/Emby.Naming/Common/MediaType.cs b/Emby.Naming/Common/MediaType.csindex a7b08bf793..a61f10489c 100644--- a/Emby.Naming/Common/MediaType.cs+++ b/Emby.Naming/Common/MediaType.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Common{public enum MediaTypediff --git a/Emby.Naming/Common/NamingOptions.cs b/Emby.Naming/Common/NamingOptions.csindex 4c2c43437a..69e68660d4 100644--- a/Emby.Naming/Common/NamingOptions.cs+++ b/Emby.Naming/Common/NamingOptions.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Linq;using System.Text.RegularExpressions;diff --git a/Emby.Naming/Emby.Naming.csproj b/Emby.Naming/Emby.Naming.csprojindex 7258beaf49..c69b36894c 100644--- a/Emby.Naming/Emby.Naming.csproj+++ b/Emby.Naming/Emby.Naming.csproj@@ -6,6 +6,10 @@<GenerateDocumentationFile>true</GenerateDocumentationFile></PropertyGroup>+ <PropertyGroup Condition=" '$(Configuration)' == 'Release' ">+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>+ </PropertyGroup>+<ItemGroup><Compile Include="..\SharedVersion.cs" /></ItemGroup>@@ -21,13 +25,13 @@<RepositoryUrl>https://github.com/jellyfin/jellyfin</RepositoryUrl></PropertyGroup>- <!-- Code analysers-->- <ItemGroup Condition=" '$(Configuration)' == 'Debug' ">+ <!-- Code Analyzers-->+ <!-- <ItemGroup Condition=" '$(Configuration)' == 'Debug' "><PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.7" PrivateAssets="All" /><PackageReference Include="SerilogAnalyzer" Version="0.15.0" PrivateAssets="All" /><PackageReference Include="StyleCop.Analyzers" Version="1.1.118" PrivateAssets="All" /><PackageReference Include="SmartAnalyzers.MultithreadingAnalyzer" Version="1.1.31" PrivateAssets="All" />- </ItemGroup>+ </ItemGroup>--><PropertyGroup Condition=" '$(Configuration)' == 'Debug' "><CodeAnalysisRuleSet>../jellyfin.ruleset</CodeAnalysisRuleSet>diff --git a/Emby.Naming/Subtitles/SubtitleInfo.cs b/Emby.Naming/Subtitles/SubtitleInfo.csindex 96fce04d76..fe42846c61 100644--- a/Emby.Naming/Subtitles/SubtitleInfo.cs+++ b/Emby.Naming/Subtitles/SubtitleInfo.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Subtitles{public class SubtitleInfodiff --git a/Emby.Naming/Subtitles/SubtitleParser.cs b/Emby.Naming/Subtitles/SubtitleParser.csindex ac9432d57d..99680c6221 100644--- a/Emby.Naming/Subtitles/SubtitleParser.cs+++ b/Emby.Naming/Subtitles/SubtitleParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.IO;using System.Linq;diff --git a/Emby.Naming/TV/EpisodeInfo.cs b/Emby.Naming/TV/EpisodeInfo.csindex de79b8bbaf..667129a57d 100644--- a/Emby.Naming/TV/EpisodeInfo.cs+++ b/Emby.Naming/TV/EpisodeInfo.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.TV{public class EpisodeInfodiff --git a/Emby.Naming/TV/EpisodePathParser.cs b/Emby.Naming/TV/EpisodePathParser.csindex a98e8221a5..4fac543f92 100644--- a/Emby.Naming/TV/EpisodePathParser.cs+++ b/Emby.Naming/TV/EpisodePathParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Collections.Generic;using System.Globalization;diff --git a/Emby.Naming/TV/EpisodePathParserResult.cs b/Emby.Naming/TV/EpisodePathParserResult.csindex 996edfc506..3acbbc101c 100644--- a/Emby.Naming/TV/EpisodePathParserResult.cs+++ b/Emby.Naming/TV/EpisodePathParserResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.TV{public class EpisodePathParserResultdiff --git a/Emby.Naming/TV/EpisodeResolver.cs b/Emby.Naming/TV/EpisodeResolver.csindex 2d7bcb6382..5e115fc75d 100644--- a/Emby.Naming/TV/EpisodeResolver.cs+++ b/Emby.Naming/TV/EpisodeResolver.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.IO;using System.Linq;diff --git a/Emby.Naming/TV/SeasonPathParser.cs b/Emby.Naming/TV/SeasonPathParser.csindex f34faf8e83..e5f90e9660 100644--- a/Emby.Naming/TV/SeasonPathParser.cs+++ b/Emby.Naming/TV/SeasonPathParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Globalization;using System.IO;diff --git a/Emby.Naming/TV/SeasonPathParserResult.cs b/Emby.Naming/TV/SeasonPathParserResult.csindex 548dbd5d22..57c2347548 100644--- a/Emby.Naming/TV/SeasonPathParserResult.cs+++ b/Emby.Naming/TV/SeasonPathParserResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.TV{public class SeasonPathParserResultdiff --git a/Emby.Naming/Video/CleanDateTimeParser.cs b/Emby.Naming/Video/CleanDateTimeParser.csindex c6b6039d4d..a9db4ccccd 100644--- a/Emby.Naming/Video/CleanDateTimeParser.cs+++ b/Emby.Naming/Video/CleanDateTimeParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Globalization;using System.IO;diff --git a/Emby.Naming/Video/CleanDateTimeResult.cs b/Emby.Naming/Video/CleanDateTimeResult.csindex 6bf24e4d85..a7581972e4 100644--- a/Emby.Naming/Video/CleanDateTimeResult.cs+++ b/Emby.Naming/Video/CleanDateTimeResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Video{public class CleanDateTimeResult@@ -7,11 +10,13 @@ namespace Emby.Naming.Video/// </summary>/// <value>The name.</value>public string Name { get; set; }+/// <summary>/// Gets or sets the year./// </summary>/// <value>The year.</value>public int? Year { get; set; }+/// <summary>/// Gets or sets a value indicating whether this instance has changed./// </summary>diff --git a/Emby.Naming/Video/CleanStringParser.cs b/Emby.Naming/Video/CleanStringParser.csindex 02b90310d7..be028c662e 100644--- a/Emby.Naming/Video/CleanStringParser.cs+++ b/Emby.Naming/Video/CleanStringParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System.Collections.Generic;using System.Text.RegularExpressions;diff --git a/Emby.Naming/Video/CleanStringResult.cs b/Emby.Naming/Video/CleanStringResult.csindex b3bc597125..786fe9e028 100644--- a/Emby.Naming/Video/CleanStringResult.cs+++ b/Emby.Naming/Video/CleanStringResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Video{public class CleanStringResult@@ -7,6 +10,7 @@ namespace Emby.Naming.Video/// </summary>/// <value>The name.</value>public string Name { get; set; }+/// <summary>/// Gets or sets a value indicating whether this instance has changed./// </summary>diff --git a/Emby.Naming/Video/ExtraResolver.cs b/Emby.Naming/Video/ExtraResolver.csindex 9f70494d01..989ede206e 100644--- a/Emby.Naming/Video/ExtraResolver.cs+++ b/Emby.Naming/Video/ExtraResolver.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.IO;using System.Linq;diff --git a/Emby.Naming/Video/ExtraResult.cs b/Emby.Naming/Video/ExtraResult.csindex ff6f20c47f..6081a44942 100644--- a/Emby.Naming/Video/ExtraResult.cs+++ b/Emby.Naming/Video/ExtraResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Video{public class ExtraResult@@ -7,6 +10,7 @@ namespace Emby.Naming.Video/// </summary>/// <value>The type of the extra.</value>public string ExtraType { get; set; }+/// <summary>/// Gets or sets the rule./// </summary>diff --git a/Emby.Naming/Video/ExtraRule.cs b/Emby.Naming/Video/ExtraRule.csindex b8eb8427e7..cfce79fd08 100644--- a/Emby.Naming/Video/ExtraRule.cs+++ b/Emby.Naming/Video/ExtraRule.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using Emby.Naming.Common;namespace Emby.Naming.Video@@ -9,16 +12,19 @@ namespace Emby.Naming.Video/// </summary>/// <value>The token.</value>public string Token { get; set; }+/// <summary>/// Gets or sets the type of the extra./// </summary>/// <value>The type of the extra.</value>public string ExtraType { get; set; }+/// <summary>/// Gets or sets the type of the rule./// </summary>/// <value>The type of the rule.</value>public ExtraRuleType RuleType { get; set; }+/// <summary>/// Gets or sets the type of the media./// </summary>diff --git a/Emby.Naming/Video/ExtraRuleType.cs b/Emby.Naming/Video/ExtraRuleType.csindex 565239ff9a..2bf2799ff7 100644--- a/Emby.Naming/Video/ExtraRuleType.cs+++ b/Emby.Naming/Video/ExtraRuleType.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Video{public enum ExtraRuleType@@ -6,10 +9,12 @@ namespace Emby.Naming.Video/// The suffix/// </summary>Suffix = 0,+/// <summary>/// The filename/// </summary>Filename = 1,+/// <summary>/// The regex/// </summary>diff --git a/Emby.Naming/Video/FileStack.cs b/Emby.Naming/Video/FileStack.csindex 584bdf2d2f..56adf6add0 100644--- a/Emby.Naming/Video/FileStack.cs+++ b/Emby.Naming/Video/FileStack.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Collections.Generic;using System.Linq;@@ -6,15 +9,17 @@ namespace Emby.Naming.Video{public class FileStack{- public string Name { get; set; }- public List<string> Files { get; set; }- public bool IsDirectoryStack { get; set; }-public FileStack(){Files = new List<string>();}+ public string Name { get; set; }++ public List<string> Files { get; set; }++ public bool IsDirectoryStack { get; set; }+public bool ContainsFile(string file, bool isDirectory){if (IsDirectoryStack == isDirectory)diff --git a/Emby.Naming/Video/FlagParser.cs b/Emby.Naming/Video/FlagParser.csindex bb129499be..acf3438c22 100644--- a/Emby.Naming/Video/FlagParser.cs+++ b/Emby.Naming/Video/FlagParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.IO;using Emby.Naming.Common;diff --git a/Emby.Naming/Video/Format3DParser.cs b/Emby.Naming/Video/Format3DParser.csindex 333a48641e..25905f33c1 100644--- a/Emby.Naming/Video/Format3DParser.cs+++ b/Emby.Naming/Video/Format3DParser.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Linq;using Emby.Naming.Common;diff --git a/Emby.Naming/Video/Format3DResult.cs b/Emby.Naming/Video/Format3DResult.csindex 40fc31e082..6ebd72f6ba 100644--- a/Emby.Naming/Video/Format3DResult.cs+++ b/Emby.Naming/Video/Format3DResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System.Collections.Generic;namespace Emby.Naming.Videodiff --git a/Emby.Naming/Video/Format3DRule.cs b/Emby.Naming/Video/Format3DRule.csindex dc260175af..ae9fb5b19f 100644--- a/Emby.Naming/Video/Format3DRule.cs+++ b/Emby.Naming/Video/Format3DRule.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Video{public class Format3DRule@@ -7,6 +10,7 @@ namespace Emby.Naming.Video/// </summary>/// <value>The token.</value>public string Token { get; set; }+/// <summary>/// Gets or sets the preceeding token./// </summary>diff --git a/Emby.Naming/Video/StackResolver.cs b/Emby.Naming/Video/StackResolver.csindex b8ba42da4f..e7a769ae6b 100644--- a/Emby.Naming/Video/StackResolver.cs+++ b/Emby.Naming/Video/StackResolver.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Collections.Generic;using System.IO;diff --git a/Emby.Naming/Video/StackResult.cs b/Emby.Naming/Video/StackResult.csindex de35d2825a..31ef2d69c5 100644--- a/Emby.Naming/Video/StackResult.cs+++ b/Emby.Naming/Video/StackResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System.Collections.Generic;namespace Emby.Naming.Videodiff --git a/Emby.Naming/Video/StubResolver.cs b/Emby.Naming/Video/StubResolver.csindex b78244cb33..bbf399677d 100644--- a/Emby.Naming/Video/StubResolver.cs+++ b/Emby.Naming/Video/StubResolver.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.IO;using System.Linq;diff --git a/Emby.Naming/Video/StubResult.cs b/Emby.Naming/Video/StubResult.csindex 7a62e7b981..5ac85528f5 100644--- a/Emby.Naming/Video/StubResult.cs+++ b/Emby.Naming/Video/StubResult.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Video{public struct StubResultdiff --git a/Emby.Naming/Video/StubTypeRule.cs b/Emby.Naming/Video/StubTypeRule.csindex d765321504..17c3ef8c5e 100644--- a/Emby.Naming/Video/StubTypeRule.cs+++ b/Emby.Naming/Video/StubTypeRule.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+namespace Emby.Naming.Video{public class StubTypeRulediff --git a/Emby.Naming/Video/VideoFileInfo.cs b/Emby.Naming/Video/VideoFileInfo.csindex 2f42f77845..250a1ec45d 100644--- a/Emby.Naming/Video/VideoFileInfo.cs+++ b/Emby.Naming/Video/VideoFileInfo.cs@@ -77,6 +77,7 @@ namespace Emby.Naming.Video/// <value>The file name without extension.</value>public string FileNameWithoutExtension => !IsDirectory ? System.IO.Path.GetFileNameWithoutExtension(Path) : System.IO.Path.GetFileName(Path);+ /// <inheritdoc />public override string ToString(){// Makes debugging easierdiff --git a/Emby.Naming/Video/VideoInfo.cs b/Emby.Naming/Video/VideoInfo.csindex f576b6ca28..a585bb99a2 100644--- a/Emby.Naming/Video/VideoInfo.cs+++ b/Emby.Naming/Video/VideoInfo.cs@@ -7,6 +7,16 @@ namespace Emby.Naming.Video/// </summary>public class VideoInfo{+ /// <summary>+ /// Initializes a new instance of the <see cref="VideoInfo" /> class.+ /// </summary>+ public VideoInfo()+ {+ Files = new List<VideoFileInfo>();+ Extras = new List<VideoFileInfo>();+ AlternateVersions = new List<VideoFileInfo>();+ }+/// <summary>/// Gets or sets the name./// </summary>@@ -36,12 +46,5 @@ namespace Emby.Naming.Video/// </summary>/// <value>The alternate versions.</value>public List<VideoFileInfo> AlternateVersions { get; set; }-- public VideoInfo()- {- Files = new List<VideoFileInfo>();- Extras = new List<VideoFileInfo>();- AlternateVersions = new List<VideoFileInfo>();- }}}diff --git a/Emby.Naming/Video/VideoListResolver.cs b/Emby.Naming/Video/VideoListResolver.csindex 5fa0041e07..5a32846bf3 100644--- a/Emby.Naming/Video/VideoListResolver.cs+++ b/Emby.Naming/Video/VideoListResolver.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.Collections.Generic;using System.IO;diff --git a/Emby.Naming/Video/VideoResolver.cs b/Emby.Naming/Video/VideoResolver.csindex 91f443500f..5a93e1eafe 100644--- a/Emby.Naming/Video/VideoResolver.cs+++ b/Emby.Naming/Video/VideoResolver.cs@@ -1,3 +1,6 @@+#pragma warning disable CS1591+#pragma warning disable SA1600+using System;using System.IO;using System.Linq;diff --git a/Emby.Photos/Emby.Photos.csproj b/Emby.Photos/Emby.Photos.csprojindex 64692c3703..4bd0f1e4a1 100644--- a/Emby.Photos/Emby.Photos.csproj+++ b/Emby.Photos/Emby.Photos.csproj@@ -1,5 +1,9 @@<Project Sdk="Microsoft.NET.Sdk">+ <PropertyGroup Condition=" '$(Configuration)' == 'Release' ">+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>+ </PropertyGroup>+<ItemGroup><ProjectReference Include="..\MediaBrowser.Controller\MediaBrowser.Controller.csproj" /><ProjectReference Include="..\MediaBrowser.Model\MediaBrowser.Model.csproj" />@@ -20,12 +24,12 @@<TreatWarningsAsErrors>true</TreatWarningsAsErrors></PropertyGroup>- <!-- Code analysers-->- <ItemGroup Condition=" '$(Configuration)' == 'Debug' ">+ <!-- Code Analyzers-->+ <!--<ItemGroup Condition=" '$(Configuration)' == 'Debug' "><PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.7" /><PackageReference Include="StyleCop.Analyzers" Version="1.1.118" /><PackageReference Include="SerilogAnalyzer" Version="0.15.0" />- </ItemGroup>+ </ItemGroup>--><PropertyGroup Condition=" '$(Configuration)' == 'Debug' "><CodeAnalysisRuleSet>../jellyfin.ruleset</CodeAnalysisRuleSet>diff --git a/Emby.Server.Implementations/Emby.Server.Implementations.csproj b/Emby.Server.Implementations/Emby.Server.Implementations.csprojindex fde4d70599..6b45f75bca 100644--- a/Emby.Server.Implementations/Emby.Server.Implementations.csproj+++ b/Emby.Server.Implementations/Emby.Server.Implementations.csproj@@ -50,13 +50,13 @@<GenerateDocumentationFile>true</GenerateDocumentationFile></PropertyGroup>- <!-- Code analysers-->- <ItemGroup Condition=" '$(Configuration)' == 'Debug' ">+ <!-- Code Analyzers-->+ <!--<ItemGroup Condition=" '$(Configuration)' == 'Debug' "><PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.7" /><PackageReference Include="SerilogAnalyzer" Version="0.15.0" /><PackageReference Include="StyleCop.Analyzers" Version="1.1.118" /><PackageReference Include="SmartAnalyzers.MultithreadingAnalyzer" Version="1.1.31" />- </ItemGroup>+ </ItemGroup>--><PropertyGroup Condition=" '$(Configuration)' == 'Debug' "><CodeAnalysisRuleSet>../jellyfin.ruleset</CodeAnalysisRuleSet>diff --git a/Emby.Server.Implementations/Library/UserManager.cs b/Emby.Server.Implementations/Library/UserManager.csindex 85bfa154af..fd414616f1 100644--- a/Emby.Server.Implementations/Library/UserManager.cs+++ b/Emby.Server.Implementations/Library/UserManager.cs@@ -392,7 +392,7 @@ namespace Emby.Server.Implementations.Libraryif (providers.Length == 0){// Assign the user to the InvalidAuthProvider since no configured auth provider was valid/found- _logger.LogWarning("User {UserName} was found with invalid/missing Authentication Provider {AuthenticationProviderId}. Assigning user to InvalidAuthProvider until this is corrected", user.Name, user.Policy.AuthenticationProviderId);+ _logger.LogWarning("User {UserName} was found with invalid/missing Authentication Provider {AuthenticationProviderId}. Assigning user to InvalidAuthProvider until this is corrected", user?.Name, user?.Policy.AuthenticationProviderId);providers = new IAuthenticationProvider[] { _invalidAuthProvider };}@@ -472,7 +472,7 @@ namespace Emby.Server.Implementations.Libraryif (!success&& _networkManager.IsInLocalNetwork(remoteEndPoint)- && user.Configuration.EnableLocalPassword+ && user?.Configuration.EnableLocalPassword == true&& !string.IsNullOrEmpty(user.EasyPassword)){// Check easy passworddiff --git a/Emby.Server.Implementations/LiveTv/EmbyTV/DirectRecorder.cs b/Emby.Server.Implementations/LiveTv/EmbyTV/DirectRecorder.csindex 8dee7046e7..84e8c31f95 100644--- a/Emby.Server.Implementations/LiveTv/EmbyTV/DirectRecorder.cs+++ b/Emby.Server.Implementations/LiveTv/EmbyTV/DirectRecorder.cs@@ -1,5 +1,6 @@using System;using System.IO;+using System.Net.Http;using System.Threading;using System.Threading.Tasks;using MediaBrowser.Common.Net;@@ -74,7 +75,7 @@ namespace Emby.Server.Implementations.LiveTv.EmbyTVDecompressionMethod = CompressionMethod.None};- using (var response = await _httpClient.SendAsync(httpRequestOptions, "GET").ConfigureAwait(false))+ using (var response = await _httpClient.SendAsync(httpRequestOptions, HttpMethod.Get).ConfigureAwait(false)){_logger.LogInformation("Opened recording stream from tuner provider");diff --git a/Emby.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs b/Emby.Server.Implementations/LiveTv/Listings/SchedulesDirect.csindex 838ac97d77..1dd794da0d 100644--- a/Emby.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs+++ b/Emby.Server.Implementations/LiveTv/Listings/SchedulesDirect.cs@@ -5,6 +5,7 @@ using System.Globalization;using System.IO;using System.Linq;using System.Net;+using System.Net.Http;using System.Threading;using System.Threading.Tasks;using MediaBrowser.Common;@@ -12,7 +13,6 @@ using MediaBrowser.Common.Net;using MediaBrowser.Controller.LiveTv;using MediaBrowser.Model.Dto;using MediaBrowser.Model.Entities;-using MediaBrowser.Model.Extensions;using MediaBrowser.Model.LiveTv;using MediaBrowser.Model.Net;using MediaBrowser.Model.Serialization;@@ -663,7 +663,7 @@ namespace Emby.Server.Implementations.LiveTv.Listingstry{- return await _httpClient.SendAsync(options, "GET").ConfigureAwait(false);+ return await _httpClient.SendAsync(options, HttpMethod.Get).ConfigureAwait(false);}catch (HttpException ex){@@ -738,7 +738,7 @@ namespace Emby.Server.Implementations.LiveTv.ListingshttpOptions.RequestHeaders["token"] = token;- using (await _httpClient.SendAsync(httpOptions, "PUT").ConfigureAwait(false))+ using (await _httpClient.SendAsync(httpOptions, HttpMethod.Put).ConfigureAwait(false)){}}diff --git a/Emby.Server.Implementations/LiveTv/TunerHosts/SharedHttpStream.cs b/Emby.Server.Implementations/LiveTv/TunerHosts/SharedHttpStream.csindex 7584953624..0d94f4b329 100644--- a/Emby.Server.Implementations/LiveTv/TunerHosts/SharedHttpStream.cs+++ b/Emby.Server.Implementations/LiveTv/TunerHosts/SharedHttpStream.cs@@ -1,6 +1,7 @@using System;using System.Collections.Generic;using System.IO;+using System.Net.Http;using System.Threading;using System.Threading.Tasks;using MediaBrowser.Common.Configuration;@@ -64,7 +65,7 @@ namespace Emby.Server.Implementations.LiveTv.TunerHostshttpRequestOptions.RequestHeaders[header.Key] = header.Value;}- var response = await _httpClient.SendAsync(httpRequestOptions, "GET").ConfigureAwait(false);+ var response = await _httpClient.SendAsync(httpRequestOptions, HttpMethod.Get).ConfigureAwait(false);var extension = "ts";var requiresRemux = false;diff --git a/Emby.Server.Implementations/Updates/InstallationManager.cs b/Emby.Server.Implementations/Updates/InstallationManager.csindex 2705e0628b..c897036eb8 100644--- a/Emby.Server.Implementations/Updates/InstallationManager.cs+++ b/Emby.Server.Implementations/Updates/InstallationManager.cs@@ -1,10 +1,10 @@using System;using System.Collections.Concurrent;using System.Collections.Generic;-using System.Globalization;using System.IO;using System.Linq;using System.Net.Http;+using System.Runtime.CompilerServices;using System.Security.Cryptography;using System.Threading;using System.Threading.Tasks;@@ -189,7 +189,7 @@ namespace Emby.Server.Implementations.Updates}/// <inheritdoc />- public async IAsyncEnumerable<PackageVersionInfo> GetAvailablePluginUpdates(CancellationToken cancellationToken = default)+ public async IAsyncEnumerable<PackageVersionInfo> GetAvailablePluginUpdates([EnumeratorCancellation] CancellationToken cancellationToken = default){var catalog = await GetAvailablePackages(cancellationToken).ConfigureAwait(false);diff --git a/Jellyfin.Api/Jellyfin.Api.csproj b/Jellyfin.Api/Jellyfin.Api.csprojindex a2818b45da..73ffaa53d9 100644--- a/Jellyfin.Api/Jellyfin.Api.csproj+++ b/Jellyfin.Api/Jellyfin.Api.csproj@@ -17,7 +17,7 @@<ProjectReference Include="..\MediaBrowser.Controller\MediaBrowser.Controller.csproj" /></ItemGroup>- <!-- Code analysers-->+ <!-- Code Analyzers--><ItemGroup Condition=" '$(Configuration)' == 'Debug' "><PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.7" PrivateAssets="All" /><PackageReference Include="SerilogAnalyzer" Version="0.15.0" PrivateAssets="All" />diff --git a/Jellyfin.Server/Jellyfin.Server.csproj b/Jellyfin.Server/Jellyfin.Server.csprojindex 110028176c..5ec791af9a 100644--- a/Jellyfin.Server/Jellyfin.Server.csproj+++ b/Jellyfin.Server/Jellyfin.Server.csproj@@ -24,8 +24,8 @@<ItemGroup><FrameworkReference Include="Microsoft.AspNetCore.App" /></ItemGroup>-- <!-- Code analyzers-->++ <!-- Code Analyzers--><ItemGroup Condition=" '$(Configuration)' == 'Debug' "><PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.7" /><PackageReference Include="SerilogAnalyzer" Version="0.15.0" />