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

#326: redirect user to welcome and show disclaimer in every page #367

Open
wants to merge 2 commits into
base: feature/polling-service-producer
Choose a base branch
from

Conversation

MirelXhafa
Copy link

No description provided.

@MirelXhafa MirelXhafa requested a review from ashishjur July 31, 2020 10:13
Copy link

@ashishjur ashishjur left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Disclaimer footnote comes on every page 👍
I don't see it redirecting to welcome wizard in case the user is not in our DB.

You can test welcome wizard by creating a new user.
A handy app to randomly create a new user https://vechainaddress.abyteahead.com/

@@ -79,8 +80,10 @@ export function* checkUserExist(action) {
log("checkUserExist - error.response", error.response);
if (error.response.status === 404) {
log("checkUserExist - error.response.status", error.response.status);
put(push("/"));

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we yield on this put call?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Redirection is made on saga so if the user tries to access the page directly from url then it will be redirected to homepage and if he has not seen welcome wizard will be displayed otherwise the disclaimer will be shown but not redirected to welcome wizard

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also expect that to happen, but it didn't happen when I tried with a new user to visit http://localhost:3000/profile/my-advocacy

The user wasn't redirected. I think a better solution is to rely on the cookie that @marcomarasco talked about.

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.

2 participants