Skip to content

[Bug]: expired user token #198

@sequensucks

Description

@sequensucks

Expected Behavior

Question/expected result.
What to do when user token is expired but page was not reload?

Actual Behavior

when u stay a long in account and try to change address u r getting error in methods save, update

request to api/magento/createCustomerAddress
getting an error in console
useAddresses/save TypeError: Cannot read properties of undefined (reading 'createCustomerAddress')

const {
remove,
update,
save,
error: errorAddresses
} = useAddresses();
and in error

width=200,height=183

Possible Solution

  1. Handle token expiration
  2. Redirect to the homepage
  3. Display a notification about logging out because of inactivity
  4. Remove the "Remember me" checkbox from the login popup
  5. Update the docs and stand out that we use default Magento process

Steps to reproduce

  1. Log in. to customer account
  2. got to my account
  3. go to address details
  4. click: change address
  5. Wait for session expired, or remove vsf-customer cookie
  6. Submit form
  7. Observe the error

What version of Magento 2 integration are you using?

2.4.3

What version of Node.js are you using?

v14.17.5

What browser (and version) are you using?

Chrome Version 94.0.4606.71 (Official Build) (x86_64)

What operating system (and version) are you using?

macOS Version 11.6 (20G165)

Relevant log output

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingvsf_team

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions