Watch
1
0
Fork
You've already forked test-web
0
test-web/src/Core/Users/GetUsersEndpoint.cs
Chris Dill 0e79a8eb5e
All checks were successful
Build / build (push) Successful in 52s
Initial commit
2026-05-30 12:26:50 +01:00

13 lines
310 B
C#

using TestWeb.Infra;
using TestWeb.Utils;
namespace TestWeb.Core.Users;
public static class GetUsersEndpoint
{
public static async Task<Ok<User[]>> Handle(AppDbContext db, CancellationToken ct)
{
var results = await db.Users.ToArrayAsync(ct);
return TypedResults.Ok(results);
}
}