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

[BUG] Hybrid session not restored after logging in via PWA once dwsid exists #738

Closed
sandragolden opened this issue Sep 28, 2022 · 2 comments
Labels
Acknowledged Team has responded to issue

Comments

@sandragolden
Copy link
Contributor

Summary

Removing the session bridge in PR #684 breaks phased rollout approach when switching between PWA and SFRA as a guest and registered customer.

Steps To Reproduce

  1. start out on pwa, add products to guest cart
  2. cart page redirects to SFRA cart page, session is successfully restored from PWA refresh token
  3. on SFRA login page, click "login" -> returns to PWA for login
  4. login via PWA
  5. return to SFRA cart page. notice that the previous guest dwsid is still set and onSession is never triggered on SFRA, resulting in a cleared guest cart. Customer is not logged in via SFRA.

Expected result

Returning to SFRA after logging in via PWA should maintain session state and cart

Additional information

Adding back the code removed in PR #684 fixes this issue.

Current State:
Notice that returning to SFRA the second time never calls onSession so the dwsid is never set from the logged in refresh token. The old dwsid from the initial session is used, resulting in an empty cart. There's no way to login via SFRA.

current-state-720.mov

Updated State

added-session-bridge-back-720.mov
@bfeister
Copy link
Collaborator

@vcua-mobify
Copy link
Contributor

The code for triggering the OCAPI session bridge has been re-added in release 2.7.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Acknowledged Team has responded to issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants