Skip to content

Commit fa083ef

Browse files
authored
Add rate limiting to API resource endpoint
Added missing line defining app
1 parent f5dce3e commit fa083ef

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

aspnetcore/performance/rate-limit.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -420,6 +420,8 @@ builder.Services.AddRateLimiter(options =>
420420
});
421421
});
422422

423+
var app = builder.Build();
424+
423425
app.MapGet("/api/resource", () => "This endpoint uses multiple limiters")
424426
.RequireRateLimiting("combined");
425427
```

0 commit comments

Comments
 (0)