Skip to content

Commit

Permalink
fixed type errors
Browse files Browse the repository at this point in the history
  • Loading branch information
DonKoko committed Nov 18, 2024
1 parent cd6304f commit 50aa3b7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/components/user/change-email.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,8 @@ export const ChangeEmailForm = ({ currentEmail }: { currentEmail: string }) => {
if ("awaitingOtp" in actionData && actionData.awaitingOtp) {
setFormState({
isAwaitingOtp: true,
newEmail: "newEmail" in actionData ? actionData.newEmail : null,
newEmail:
"newEmail" in actionData ? (actionData.newEmail as string) : null,
});
}

Expand Down
1 change: 1 addition & 0 deletions app/routes/_layout+/account-details.general.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,7 @@ export async function action({ context, request }: ActionFunctionArgs) {
data({
awaitingOtp: true,
newEmail, // We'll need this to show which email we're waiting for verification
success: true,
})
);
}
Expand Down

0 comments on commit 50aa3b7

Please sign in to comment.