Skip to content
Merged

Tali #39

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion components/auth/ResendOtpForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,15 @@ interface ResendOtpFormProps {
export default function ResendOtpForm({ email, onResent }: ResendOtpFormProps) {
const [apiMessage, setApiMessage] = useState<string | null>(null);
const [loading, setLoading] = useState(false);
const url = process.env.NEXT_PUBLIC_BACKEND_URL

const handleResend = async (e: React.FormEvent) => {
e.preventDefault();
setApiMessage(null);
setLoading(true);
try {
const res = await fetch(
'https://velo-node-backend.onrender.com/auth/resend-otp',
`${url}/auth/resend-otp`,
{
method: 'POST',
headers: { 'Content-Type': 'application/json' },
Expand Down
Loading