diff --git a/src/utils/rest-api.js b/src/utils/rest-api.js index bffc09c..4bc0f23 100644 --- a/src/utils/rest-api.js +++ b/src/utils/rest-api.js @@ -161,14 +161,18 @@ export function fetchAuthorizationCodeFlowFeatureFlag() { return fetch('env.json') .then((res) => res.json()) .then((res) => { - console.log( - `Authorization code flow is ${ - res.authorizationCodeFlowFeatureFlag - ? 'enabled' - : 'disabled' - }` - ); - return res.authorizationCodeFlowFeatureFlag; + return fetch(res.appsMetadataServerUrl + '/login.json') + .then((res) => res.json()) + .then((res) => { + console.log( + `Authorization code flow is ${ + res.authorizationCodeFlowFeatureFlag + ? 'enabled' + : 'disabled' + }` + ); + return res.authorizationCodeFlowFeatureFlag; + }); }); }