Resolve some warnings

This commit is contained in:
Archi
2023-11-27 13:01:52 +01:00
parent 306fbef3c2
commit a59087b574
3 changed files with 4 additions and 4 deletions

View File

@@ -114,6 +114,7 @@ dotnet_code_quality_unused_parameters = all:warning
dotnet_diagnostic.ca1028.severity = silent dotnet_diagnostic.ca1028.severity = silent
dotnet_diagnostic.ca1031.severity = silent dotnet_diagnostic.ca1031.severity = silent
dotnet_diagnostic.ca1863.severity = silent
# Rule - almost everything # Rule - almost everything
dotnet_naming_rule.almost_everything_must_be_pascal_case.severity = warning dotnet_naming_rule.almost_everything_must_be_pascal_case.severity = warning

View File

@@ -21,6 +21,7 @@
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;
using System.Globalization; using System.Globalization;
using System.Linq; using System.Linq;
using System.Net; using System.Net;
@@ -41,6 +42,7 @@ public sealed class TypeController : ArchiController {
/// <remarks> /// <remarks>
/// Type info is defined as a representation of given object with its fields and properties being assigned to a string value that defines their type. /// Type info is defined as a representation of given object with its fields and properties being assigned to a string value that defines their type.
/// </remarks> /// </remarks>
[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicFields | DynamicallyAccessedMemberTypes.NonPublicFields)]
[HttpGet("{type:required}")] [HttpGet("{type:required}")]
[ProducesResponseType<GenericResponse<TypeResponse>>((int) HttpStatusCode.OK)] [ProducesResponseType<GenericResponse<TypeResponse>>((int) HttpStatusCode.OK)]
[ProducesResponseType<GenericResponse>((int) HttpStatusCode.BadRequest)] [ProducesResponseType<GenericResponse>((int) HttpStatusCode.BadRequest)]

View File

@@ -50,10 +50,7 @@
<DebugType>none</DebugType> <DebugType>none</DebugType>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors> <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<WarningsAsErrors /> <WarningsAsErrors />
<WarningsNotAsErrors>CS8002,IL2026,IL2057,IL2072,IL2075,IL2104,IL3000</WarningsNotAsErrors> <WarningsNotAsErrors>CA1863,CS8002,IL2026,IL2057,IL2072,IL2075,IL2104,IL3000</WarningsNotAsErrors>
<!-- TODO: .NET 8 -->
<WarningsNotAsErrors>$(WarningsNotAsErrors),CA1863</WarningsNotAsErrors>
</PropertyGroup> </PropertyGroup>
<!-- Enable public signing if not part of Visual Studio, which is too stupid to understand what public signing is --> <!-- Enable public signing if not part of Visual Studio, which is too stupid to understand what public signing is -->