Skip to content
This repository has been archived by the owner. It is now read-only.

Commit be27012

Browse files
committed
Set authority value in applicationConfig.
- This is to allow configurable authority for different tenancy.
1 parent f1dadea commit be27012

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

JavaScriptSPA/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,12 @@ <h4 id="WelcomeMessage"></h4>
1616
<script>
1717
var applicationConfig = {
1818
clientID: 'Enter_the_Application_Id_here', //This is your client ID
19+
authority: "https://login.microsoftonline.com/common", //Default authority value is https://login.microsoftonline.com/common
1920
graphScopes: ["user.read"],
2021
graphEndpoint: "https://graph.microsoft.com/v1.0/me"
2122
};
2223

23-
//Pass null for default authority (https://login.microsoftonline.com/common)
24-
var myMSALObj = new Msal.UserAgentApplication(applicationConfig.clientID, null, acquireTokenRedirectCallBack,
24+
var myMSALObj = new Msal.UserAgentApplication(applicationConfig.clientID, applicationConfig.authority, acquireTokenRedirectCallBack,
2525
{storeAuthStateInCookie: true, cacheLocation: "localStorage"});
2626

2727
function signIn() {

0 commit comments

Comments
 (0)