chat: add hello controller

This commit is contained in:
sam 2024-05-21 17:45:35 +02:00
parent 6f6e19bbb5
commit 7b4cbd4fb7
12 changed files with 114 additions and 53 deletions

View file

@ -17,7 +17,7 @@ public class AppsController(ILogger logger, IdentityContext db) : ControllerBase
public async Task<IActionResult> CreateApplication([FromBody] Apps.CreateRequest req)
{
var app = Application.Create(req.Name, req.Scopes, req.RedirectUris);
await db.AddAsync(app);
db.Add(app);
await db.SaveChangesAsync();
logger.Information("Created new application {Name} with ID {Id} and client ID {ClientId}", app.Name, app.Id, app.ClientId);