feat: login with not existed username tip

This commit is contained in:
Tristan Yang
2022-09-06 18:46:55 +08:00
parent cb8f0c0aef
commit 293bf53258
2 changed files with 4 additions and 1 deletions
+3 -1
View File
@@ -97,7 +97,9 @@ const baseQueryWithTokenCheck = async (args, api, extraOptions) => {
break;
case 404:
{
toast.error("Request Not Found");
if (api.endpoint !== "login") {
toast.error("Request Not Found");
}
}
break;
case 500:
+1
View File
@@ -64,6 +64,7 @@ export default function LoginPage() {
if (error) {
switch ((error as FetchBaseQueryError).status) {
case 401:
case 404:
toast.error("Username or Password incorrect");
break;
case 410: