Skip to content

Commit a5edc55

Browse files
committed
remove auth changes from this pr
1 parent 5ab29b8 commit a5edc55

1 file changed

Lines changed: 3 additions & 10 deletions

File tree

src/Authentication/Authentication.Core/Utilities/AuthenticationHelpers.cs

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -127,18 +127,11 @@ private static async Task<InteractiveBrowserCredential> GetInteractiveBrowserCre
127127
if (ShouldUseWam(authContext))
128128
{
129129
GraphSession.Instance.OutputWriter.WriteWarning("Note: Sign in by Web Account Manager (WAM) is enabled by default on Windows. If using an embedded terminal, the interactive browser window may be hidden behind other windows.");
130-
authRecord = await Task.Run(() =>
131-
{
132-
return interactiveBrowserCredential.Authenticate(new TokenRequestContext(authContext.Scopes), cancellationToken);
133-
});
134130
}
135-
else
131+
authRecord = await Task.Run(() =>
136132
{
137-
authRecord = await Task.Run(() =>
138-
{
139-
return interactiveBrowserCredential.AuthenticateAsync(new TokenRequestContext(authContext.Scopes), cancellationToken);
140-
});
141-
}
133+
return interactiveBrowserCredential.Authenticate(new TokenRequestContext(authContext.Scopes), cancellationToken);
134+
});
142135
await WriteAuthRecordAsync(authRecord).ConfigureAwait(false);
143136
return interactiveBrowserCredential;
144137
}

0 commit comments

Comments
 (0)