@insforge/react 0.3.4 → 0.3.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1713,7 +1713,7 @@ function SignUp({
1713
1713
  if ("error" in result) {
1714
1714
  throw new Error(result.error);
1715
1715
  }
1716
- if (result.requiresEmailVerification && !result.accessToken) {
1716
+ if (result.requireEmailVerification && !result.accessToken) {
1717
1717
  setStep("awaiting-verification");
1718
1718
  setLoading(false);
1719
1719
  return;
@@ -2211,12 +2211,12 @@ function ForgotPassword({
2211
2211
  setError("");
2212
2212
  setVerificationCode(code);
2213
2213
  try {
2214
- const result = await insforge.auth.verifyResetPasswordCode({ email, code });
2214
+ const result = await insforge.auth.exchangeResetPasswordToken({ email, code });
2215
2215
  if (result.error) {
2216
2216
  throw new Error(result.error.message || "Failed to verify code");
2217
2217
  }
2218
2218
  if (result.data) {
2219
- setResetToken(result.data.resetToken);
2219
+ setResetToken(result.data.token);
2220
2220
  setStep("password");
2221
2221
  }
2222
2222
  } catch (err) {