Expire token after 1 hour
This commit is contained in:
@@ -40,20 +40,8 @@ export default function ResetPassword(props: any) {
|
||||
|
||||
if (!response.ok) {
|
||||
toast.dismiss();
|
||||
|
||||
if (response.status == 404) {
|
||||
toast.error("Invalid Token");
|
||||
}
|
||||
|
||||
if (response.status == 400) {
|
||||
toast.error("New password must be different");
|
||||
}
|
||||
|
||||
if (response.status == 500) {
|
||||
toast.error("Something went wrong.");
|
||||
}
|
||||
|
||||
return;
|
||||
const error = await response.json();
|
||||
toast.error(error.message);
|
||||
}
|
||||
|
||||
if (response.ok) {
|
||||
|
||||
Reference in New Issue
Block a user