Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: reload form on logout #4682

Merged
merged 2 commits into from
Aug 26, 2022
Merged

Conversation

karrui
Copy link
Contributor

@karrui karrui commented Aug 25, 2022

Problem

This PR reloads the public form page when user logs out of public form authentication.

The current double toast behaviour flagged in #4649 is due to the caching of the current public form (to prevent sudden changes to form viewed by the form filler when form is updated by the form admin), which results in the outdated toast being shown (since there was a spcpSession prop in the previous logged in state which is no longer present in the logged out state).

By reloading the page on logout, a fresh form is now loaded.

Closes #4649

Solution

Breaking Changes

  • No - this PR is backwards compatible

Bug Fixes:

  • fix: reload form on logout

@karrui karrui linked an issue Aug 25, 2022 that may be closed by this pull request
@karrui karrui merged commit bdc2e8d into form-v2/develop Aug 26, 2022
@karrui karrui deleted the form-v2/reload-on-public-logout branch August 26, 2022 02:26
@justynoh justynoh mentioned this pull request Oct 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[1] Double notification when public users logs out of Singpass
2 participants