refactor: more consistent field names, also in STYLE.md

This commit is contained in:
sam 2024-09-09 14:50:00 +02:00
parent 344a0071e5
commit c77ee660ca
Signed by: sam
GPG key ID: B4EF20DDE721CAA1
14 changed files with 86 additions and 71 deletions

View file

@ -7,7 +7,7 @@ using NodaTime;
namespace Foxnouns.Backend.Controllers.Authentication;
[Route("/api/v2/auth")]
public class AuthController(Config config, KeyCacheService keyCacheSvc, ILogger logger) : ApiControllerBase
public class AuthController(Config config, KeyCacheService keyCache, ILogger logger) : ApiControllerBase
{
private readonly ILogger _logger = logger.ForContext<AuthController>();
@ -19,7 +19,7 @@ public class AuthController(Config config, KeyCacheService keyCacheSvc, ILogger
config.DiscordAuth.Enabled,
config.GoogleAuth.Enabled,
config.TumblrAuth.Enabled);
var state = HttpUtility.UrlEncode(await keyCacheSvc.GenerateAuthStateAsync(ct));
var state = HttpUtility.UrlEncode(await keyCache.GenerateAuthStateAsync(ct));
string? discord = null;
if (config.DiscordAuth is { ClientId: not null, ClientSecret: not null })
discord =