Register endpoint

This commit is contained in:
2024-07-22 02:21:30 +02:00
parent d94c342bd6
commit af588ab174
9 changed files with 192 additions and 43 deletions
+4 -4
View File
@@ -18,7 +18,7 @@ class User extends Api
} catch (Exception $err) {
switch ($err->getMessage()) {
case "NotFound":
throw new Exception("User not Found", 404);
throw new Exception("User not found", 404);
default:
throw $err;
}
@@ -36,7 +36,7 @@ class User extends Api
} catch (Exception $err) {
switch ($err->getMessage()) {
case "NotFound":
throw new Exception("User not Found", 404);
throw new Exception("User not found", 404);
case "FailedUsername":
throw new Exception("Failed to update username", 500);
case "FailedPassword":
@@ -61,7 +61,7 @@ class User extends Api
} catch (Exception $err) {
switch ($err->getMessage()) {
case "NotFound":
throw new Exception("User not Found", 404);
throw new Exception("User not found", 404);
case "FailedUsername":
throw new Exception("Failed to update username", 500);
case "FailedPassword":
@@ -81,7 +81,7 @@ class User extends Api
} catch (Exception $err) {
switch ($err->getMessage()) {
case "NotFound":
throw new Exception("User not Found", 404);
throw new Exception("User not found", 404);
default:
throw $err;
}