feat(authentication, types): split authenticate method into two (#6184)

* init

* fetch providers using updated string

* update loaders

* add more tests

* add authenticationresponse type

* update types for authentication method

* add entity_id and update provider

* update pr with return type

* create loaders onApplicationStart

* cleanup provider class

* run application start hook before each

* fix pr feedback

* create private onApplicationStart method

* assign repository

* init

* add entity_id and update provider

* initial implementation

* update lockfile

* fix conflicts

* add config variables

* update types

* refactor google provider

* re-order methods

* fix pr feedback p. 1

* add initial type and update callback authorization

* add google provider to integration test

* fix feedback

* initial implementation (#6171)

* initial implementation

* remove oauth lib

* move abstract authentication provider

* shuffle files around

* init

* add entity_id and update provider

* initial implementation

* update lockfile

* fix conflicts

* add config variables

* update types

* refactor google provider

* re-order methods

* fix pr feedback p. 1

* add initial type and update callback authorization

* add google provider to integration test

* fix feedback

* initial implementation (#6171)

* initial implementation

* remove oauth lib

* move abstract authentication provider

* shuffle files around

* Update packages/authentication/src/migrations/Migration20240122041959.ts

Co-authored-by: Carlos R. L. Rodrigues <37986729+carlos-r-l-rodrigues@users.noreply.github.com>

* split authentication methods

* call verify with token

* update integration tests

* feedback

* rename split methods

* fix provider integration test

---------

Co-authored-by: Carlos R. L. Rodrigues <37986729+carlos-r-l-rodrigues@users.noreply.github.com>
This commit is contained in:
Philip Korsholm
2024-01-26 11:37:23 +08:00
committed by GitHub
co-authored by Carlos R. L. Rodrigues
parent 5a550e73b4
commit 638b47ff70
7 changed files with 126 additions and 87 deletions
@@ -1,5 +1,6 @@
import { IAuthenticationModuleService } from "@medusajs/types"
import { MedusaModule, Modules } from "@medusajs/modules-sdk"
import { IAuthenticationModuleService } from "@medusajs/types"
import { MikroOrmWrapper } from "../../../utils"
import { SqlEntityManager } from "@mikro-orm/postgresql"
import { createAuthProviders } from "../../../__fixtures__/auth-provider"