@trudb/tru-common-lib 0.0.709 → 0.0.710
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/lib/components/login/classes/tru-auth-strategy-provider.mjs +5 -5
- package/fesm2015/trudb-tru-common-lib.mjs +3 -3
- package/fesm2015/trudb-tru-common-lib.mjs.map +1 -1
- package/fesm2020/trudb-tru-common-lib.mjs +3 -3
- package/fesm2020/trudb-tru-common-lib.mjs.map +1 -1
- package/lib/components/login/classes/tru-auth-strategy-provider.d.ts +2 -1
- package/package.json +1 -1
|
@@ -6081,11 +6081,11 @@ class TruAuthSessionStrategy {
|
|
|
6081
6081
|
const TruAuthStrategyProvider = {
|
|
6082
6082
|
provide: TRU_AUTH_STRATEGY,
|
|
6083
6083
|
deps: [HttpClient],
|
|
6084
|
-
useFactory: (http) => {
|
|
6085
|
-
switch (
|
|
6084
|
+
useFactory: (http, appEnvironment) => {
|
|
6085
|
+
switch (appEnvironment.authType) {
|
|
6086
6086
|
case "session":
|
|
6087
6087
|
return new TruAuthSessionStrategy(http);
|
|
6088
|
-
case "
|
|
6088
|
+
case "jwt":
|
|
6089
6089
|
return new TruAuthJwtStrategy();
|
|
6090
6090
|
default:
|
|
6091
6091
|
throw new Error("Invalid auth strategy");
|