We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent dc40a59 commit 95b72e0Copy full SHA for 95b72e0
1 file changed
Applications/Backend/Source/HttpsRichardy.Federation.WebApi/Controllers/ClientsController.cs
@@ -35,8 +35,8 @@ public async Task<IActionResult> CreateClientAsync([FromBody] ClientCreationSche
35
36
return result switch
37
{
38
- { IsSuccess: true } =>
39
- StatusCode(StatusCodes.Status201Created),
+ { IsSuccess: true } when result.Data is not null =>
+ StatusCode(StatusCodes.Status201Created, result.Data),
40
41
{ IsFailure: true } when result.Error == ClientErrors.ClientAlreadyExists =>
42
StatusCode(StatusCodes.Status409Conflict, result.Error),
0 commit comments