File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,7 +12,6 @@ interface AUTH_CONFIG_SERVER_TYPE {
1212 issuer : string
1313 clientId : string
1414 clientSecret : string
15- mobileClientId : string
1615 mgmtClientId : string
1716 mgmtClientSecret : string
1817 mgmtClientAudience : string
@@ -26,7 +25,6 @@ if (typeof window === 'undefined') {
2625 issuer : checkAndPrintWarning ( 'AUTH0_DOMAIN' , process . env . AUTH0_DOMAIN ) ,
2726 clientId : checkAndPrintWarning ( 'AUTH0_CLIENT_ID' , process . env . AUTH0_CLIENT_ID ) ,
2827 clientSecret : checkAndPrintWarning ( 'AUTH0_CLIENT_SECRET' , process . env . AUTH0_CLIENT_SECRET ) ,
29- mobileClientId : checkAndPrintWarning ( 'AUTH0_MOBILE_CLIENT_ID' , process . env . AUTH0_MOBILE_CLIENT_ID ) ,
3028 mgmtClientId : checkAndPrintWarning ( 'AUTH0_MGMT_CLIENT_ID' , process . env . AUTH0_MGMT_CLIENT_ID ) ,
3129 mgmtClientSecret : checkAndPrintWarning ( 'AUTH0_MGMT_CLIENT_SECRET' , process . env . AUTH0_MGMT_CLIENT_SECRET ) ,
3230 mgmtClientAudience : checkAndPrintWarning ( 'AUTH0_MGMT_CLIENT_AUDIENCE' , process . env . AUTH0_MGMT_CLIENT_AUDIENCE ) ,
Original file line number Diff line number Diff line change @@ -4,18 +4,13 @@ import { AUTH_CONFIG_SERVER } from '../../Config'
44
55if ( AUTH_CONFIG_SERVER == null ) throw new Error ( 'AUTH_CONFIG_SERVER not defined' )
66
7- const mobileAuthSecret = process . env . MOBILE_AUTH_SECRET
8- if ( mobileAuthSecret == null ) {
9- console . warn ( 'Mobile auth secret not found' )
10- }
11-
12- const { mobileClientId, issuer } = AUTH_CONFIG_SERVER
7+ const { clientId, clientSecret, issuer } = AUTH_CONFIG_SERVER
138
14- // Set up Auth0 client for mobile with client secret for ROPG flow
9+ // Set up Auth0 client for mobile ROPG using web app credentials (confidential client)
1510export const auth0Client = new Auth0 . AuthenticationClient ( {
1611 domain : issuer . replace ( 'https://' , '' ) ,
17- clientId : mobileClientId ,
18- clientSecret : mobileAuthSecret
12+ clientId,
13+ clientSecret
1914} )
2015
2116export const isNullOrEmpty = ( str : string | null | undefined ) : boolean => {
You can’t perform that action at this time.
0 commit comments