You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cannot read properties of undefined (reading 'access_token')
Describe the bug
When login from store side using the medusa.auth.getToken({email, password}) method i get the error Cannot read properties of undefined (reading 'access_token') from @medusajs/medusa-js package, it seems that the way the package try to access to the data is wrong
This is the raw response from the server
{
"access_token": "SECRET_ACCESS_TOKEN"
}
System information
Medusa version (including plugins):
Node.js version: 16.16.0
Database: PostgreSQL 15.1 (Ubuntu 15.1-1.pgdg20.04+1) on aarch64-unknown-linux-gnu, compiled by gcc (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0, 64-bit
Operating system: Ubuntu
Browser (if relevant): Chrome (not relevant)
Steps to reproduce the behavior
Use the @medusajs/medusa-js package to try to get token medusa.auth.getToken(/**/)
See error
Expected behavior
Package returns the token
Screenshots
If applicable, add screenshots to help explain your problem
Code snippets
If applicable, add code samples to help explain your problem
Additional context
Add any other context about the problem here
The text was updated successfully, but these errors were encountered:
Bug report
Cannot read properties of undefined (reading 'access_token')
Describe the bug
When login from store side using the medusa.auth.getToken({email, password}) method i get the error
Cannot read properties of undefined (reading 'access_token')
from @medusajs/medusa-js package, it seems that the way the package try to access to the data is wrongThis is the raw response from the server
System information
Medusa version (including plugins):
Node.js version: 16.16.0
Database: PostgreSQL 15.1 (Ubuntu 15.1-1.pgdg20.04+1) on aarch64-unknown-linux-gnu, compiled by gcc (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0, 64-bit
Operating system: Ubuntu
Browser (if relevant): Chrome (not relevant)
Steps to reproduce the behavior
medusa.auth.getToken(/**/)
Expected behavior
Package returns the token
Screenshots
If applicable, add screenshots to help explain your problem
Code snippets
If applicable, add code samples to help explain your problem
Additional context
Add any other context about the problem here
The text was updated successfully, but these errors were encountered: