improvement: add more aggresive rate limiting on smtp endpoints

This commit is contained in:
Scott Wilson
2025-06-04 13:27:08 -07:00
parent 83c53b9d5a
commit 698260cba6
10 changed files with 54 additions and 22 deletions
@@ -78,11 +78,14 @@ export default function CodeInputStep({
const resendVerificationEmail = async () => {
setIsResendingVerificationEmail(true);
setIsLoading(true);
await mutateAsync({ email });
setTimeout(() => {
setIsLoading(false);
setIsResendingVerificationEmail(false);
}, 2000);
try {
await mutateAsync({ email });
} finally {
setTimeout(() => {
setIsLoading(false);
setIsResendingVerificationEmail(false);
}, 1000);
}
};
return (