🐛 Fix wrong method to configure rate limiting

This commit is contained in:
2025-10-08 18:05:59 +08:00
parent 1315c7f4d4
commit 21c99567b4

View File

@@ -24,7 +24,7 @@ builder.Services.AddCors(options =>
builder.Services.AddRateLimiter(options => builder.Services.AddRateLimiter(options =>
{ {
options.AddFixedWindowLimiter("fixed", limiterOptions => options.AddPolicy("fixed", context =>
{ {
var ip = context.Connection.RemoteIpAddress?.ToString() ?? "unknown"; var ip = context.Connection.RemoteIpAddress?.ToString() ?? "unknown";