fix: login component in app not respecting allowed auth provider ids

This commit is contained in:
Andrew Bastin
2023-08-25 19:13:03 +05:30
parent 886847ab7b
commit c62482e81f
2 changed files with 5 additions and 3 deletions

View File

@@ -312,8 +312,10 @@ const authProviders: AuthProviderItem[] = [
}, },
] ]
const allowedAuthProvidersIDsString: string | undefined = import.meta.env // Do not format the `import.meta.env.VITE_ALLOWED_AUTH_PROVIDERS` call into multiple lines!
.VITE_ALLOWED_AUTH_PROVIDERS // prettier-ignore
const allowedAuthProvidersIDsString =
import.meta.env.VITE_ALLOWED_AUTH_PROVIDERS
const allowedAuthProvidersIDs = allowedAuthProvidersIDsString const allowedAuthProvidersIDs = allowedAuthProvidersIDsString
? allowedAuthProvidersIDsString.split(",") ? allowedAuthProvidersIDsString.split(",")

View File

@@ -182,7 +182,7 @@ type InvokeActionFunc = {
* @param args The argument passed to the action handler. Optional if action has no args required * @param args The argument passed to the action handler. Optional if action has no args required
*/ */
export const invokeAction: InvokeActionFunc = < export const invokeAction: InvokeActionFunc = <
A extends HoppAction | HoppActionWithArgs A extends HoppAction | HoppActionWithArgs,
>( >(
action: A, action: A,
args: ArgOfHoppAction<A> args: ArgOfHoppAction<A>