Check if password reset link has expired

When the password reset link is no longer valid (e.g. when it was already used), I’d like to redirect the user to a page notifying them that the link is no longer valid. Right now the user only finds this out once they input the new password and click ‘Confirm’ and an error pops up. Any ideas?

It should work on page load that the link is invalid…it is controlled by Bubble

What do you mean by ‘work on page load’? Is there a conditional that I can do?

Bubble handles this stuff for you already. Check out what the manual has to say about password reset links.

When the page is loaded Bubble behind the scene checks the password reset link validity.

Are you using the built in password reset page and the built in reset password workflow?

I don’t think you understood my problem that I laid out in the first post. ‘Right now the user only finds out the link is invalid once they input the new password and click Confirm’. I want to check for link validity on page load and redirect the user to another page notifying them the link is invalid.
The manual does not say anything about being able to check whether the link is invalid or not.

Well I would like to redirect them to another page instantly if the link is invalid, how do I do that?

Like I said, Bubble handles it for you

Try the “An unhandled error occurred” event, with the condition on it Current Workflow Error's code is WRONG_PASSWORD_RESET then redirect them to the page you want. IT should suppress the native message that pops up on the browser

edit: Oops you said you want it to know right away on page load, nvm :joy: :man_shrugging:

I guess if someone does reset their password, make a new thing in your database with the token from the URL and consider that “banned” and on page load check if the current URL’s token is in your database, then redirect if true.

1 Like

Wait a minute, yes, this should work! Thank you so much!