Enable more analyzers, drop log-and-rethrow in file activities and apply dotnet format
Use invariant culture when formatting ids, put cancellation tokens last in endpoint handlers, remove the CS8618 pragmas and keep only the analyzer overrides that still apply.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
using System.Globalization;
|
||||
using System.Security.Cryptography;
|
||||
using Microsoft.IdentityModel.JsonWebTokens;
|
||||
using Microsoft.IdentityModel.Tokens;
|
||||
@@ -36,7 +37,7 @@ public sealed class TicketValidatorTests : IDisposable
|
||||
{
|
||||
var claims = new Dictionary<string, object> { ["prefix"] = prefix };
|
||||
if (maxBytes != null)
|
||||
claims["maxBytes"] = maxBytes.Value.ToString();
|
||||
claims["maxBytes"] = maxBytes.Value.ToString(CultureInfo.InvariantCulture);
|
||||
|
||||
var descriptor = new SecurityTokenDescriptor
|
||||
{
|
||||
|
||||
+2
-1
@@ -1,3 +1,4 @@
|
||||
using System.Globalization;
|
||||
using System.Security.Cryptography;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
using Microsoft.Extensions.Logging.Abstractions;
|
||||
@@ -39,7 +40,7 @@ public sealed class TicketValidationMiddlewareTests : IDisposable
|
||||
{
|
||||
var claims = new Dictionary<string, object> { ["prefix"] = prefix };
|
||||
if (maxBytes != null)
|
||||
claims["maxBytes"] = maxBytes.Value.ToString();
|
||||
claims["maxBytes"] = maxBytes.Value.ToString(CultureInfo.InvariantCulture);
|
||||
|
||||
return new JsonWebTokenHandler().CreateToken(new SecurityTokenDescriptor
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user