Auto fill OTP in modal

This commit is contained in:
2026-09-23 11:56:39 +05:30
parent 0df5fae690
commit 8876e61235
2 changed files with 6 additions and 1 deletions
+1 -1
View File
@@ -363,7 +363,7 @@ const AnalysisResultPage = () => {
setTimeout(() => setToast({ show: false, message: '' }), 4000);
} else {
setShowOtpModal(true);
setOtp(new Array(6).fill(''));
setOtp(user.otp ? user.otp.split('') : new Array(6).fill(''));
}
} catch (err) {
setFormErrors({ phone: err.message || 'Failed to send message. Please try again.' });