Replace raw environment variable reads with IConfiguration in backend

This commit is contained in:
Aaron Po
2026-08-22 20:26:13 -04:00
parent 9e9fc98d33
commit c514eb9814
17 changed files with 291 additions and 100 deletions

View File

@@ -32,7 +32,7 @@ public class JwtAuthenticationHandler(
protected override async Task<AuthenticateResult> HandleAuthenticateAsync()
{
// Use the same access-token secret source as TokenService to avoid mismatched validation.
string? secret = Environment.GetEnvironmentVariable("ACCESS_TOKEN_SECRET");
string? secret = configuration["ACCESS_TOKEN_SECRET"];
if (string.IsNullOrWhiteSpace(secret))
secret = configuration["Jwt:SecretKey"];