adrien2p / medusa-plugins

A collection of awesome plugins for medusa :rocket:
https://medusa-plugins.vercel.app
MIT License
161 stars 46 forks source link

Login Success but still 401 #97

Closed hukhho closed 1 year ago

hukhho commented 1 year ago

when i login with google, it already success, but when it return to admin dashboard it have 401, already go to localhost:7001/a/products but then it go to 401, how i can login to admin dashboard with google? image image

adrien2p commented 1 year ago

Can you share more info like the packages versions please

hukhho commented 1 year ago

"dependencies": { "@medusajs/admin": "^7.1.1", "@medusajs/cache-inmemory": "^1.8.8", "@medusajs/cache-redis": "^1.8.8", "@medusajs/event-bus-local": "^1.9.6", "@medusajs/event-bus-redis": "^1.8.9", "@medusajs/file-local": "^1.0.2", "@medusajs/icons": "^1.0.0", "@medusajs/medusa": "^1.17.0", "@medusajs/ui": "2.0", "@medusajs/ui-preset": "^1.0.1", "@tanstack/react-query": "4.22.0", "babel-preset-medusa-package": "^1.1.13", "body-parser": "^1.19.0", "cors": "^2.8.5", "dotenv": "16.0.3", "express": "^4.17.2", "medusa-fulfillment-manual": "^1.1.38", "medusa-interfaces": "^1.3.7", "medusa-payment-manual": "^1.0.24", "medusa-payment-stripe": "^6.0.4", "medusa-plugin-auth": "^1.6.0", "medusa-react": "^9.0.6", "prism-react-renderer": "^2.0.4", "typeorm": "^0.3.16" }

adrien2p commented 1 year ago

The plugin is not yet compatible with medusa 1.17 @dPreininger was keep to open a pr to make it compatible since he has worked on the auth update 👌

adrien2p commented 1 year ago

Basically, the current plugin version generates the token as it was expected by the previous versions of medusa. I have no access to my laptop for now but it is just a matter of adjusting this part.

mortenengel commented 1 year ago

@adrien2p we are having trouble with this bug as well - I tried having a look into the code to see if I could make a PR, but I haven't been able to identify where the headers need changed.

Do we have any ETA on when this can be looked into? Or can you guide me on where this change needs to be implemented?

adrien2p commented 1 year ago

There is a pr open, i am just quite busy at the moment. The pr will make it compatible with medusa 1.7

mortenengel commented 1 year ago

perfect, I will await patiently :)

adrien2p commented 1 year ago

Could you try the latest please

mortenengel commented 1 year ago

@adrien2p looks to be working perfectly for me! Good job.

Tested with @medusajs/medusa 1.17.4 and medusa-plugin-auth 1.8.1 no config changes were needed.