summary refs log tree commit diff
path: root/MxApiExtensions/Controllers/LoginController.cs
diff options
context:
space:
mode:
authorTheArcaneBrony <myrainbowdash949@gmail.com>2023-09-15 09:51:56 +0200
committerTheArcaneBrony <myrainbowdash949@gmail.com>2023-09-15 09:51:56 +0200
commit143b7fb859d97e815ed5340a1889db93e17a762e (patch)
tree91c536b15a1d60486345ebd4829bfd67e7be8018 /MxApiExtensions/Controllers/LoginController.cs
parentAdded a lot of utilities (diff)
downloadMxApiExtensions-143b7fb859d97e815ed5340a1889db93e17a762e.tar.xz
Refactors
Diffstat (limited to 'MxApiExtensions/Controllers/LoginController.cs')
-rw-r--r--MxApiExtensions/Controllers/LoginController.cs3
1 files changed, 2 insertions, 1 deletions
diff --git a/MxApiExtensions/Controllers/LoginController.cs b/MxApiExtensions/Controllers/LoginController.cs

index 1a7970a..1ad3247 100644 --- a/MxApiExtensions/Controllers/LoginController.cs +++ b/MxApiExtensions/Controllers/LoginController.cs
@@ -4,6 +4,7 @@ using LibMatrix.Extensions; using LibMatrix.Responses; using LibMatrix.Services; using Microsoft.AspNetCore.Mvc; +using MxApiExtensions.Classes.LibMatrix; using MxApiExtensions.Services; namespace MxApiExtensions.Controllers; @@ -31,7 +32,7 @@ public class LoginController : ControllerBase { Response.StatusCode = (int)StatusCodes.Status403Forbidden; Response.ContentType = "application/json"; await Response.StartAsync(); - await Response.WriteAsync(new MxApiMatrixException() { + await Response.WriteAsync(new MxApiMatrixException { ErrorCode = "M_FORBIDDEN", Error = "[MxApiExtensions] Invalid username, must be of the form @user#domain:" + Request.Host.Value }.GetAsJson() ?? "");