Skip to content
This repository has been archived by the owner on Feb 12, 2025. It is now read-only.

Commit

Permalink
Fix doc bug
Browse files Browse the repository at this point in the history
Add necessary dereference to `oauthConfig`.
  • Loading branch information
jhendrixMSFT authored Jul 22, 2019
1 parent 87cb0b4 commit 051b144
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions autorest/adal/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ resource := "https://management.core.windows.net/"
applicationSecret := "APPLICATION_SECRET"

spt, err := adal.NewServicePrincipalToken(
oauthConfig,
*oauthConfig,
appliationID,
applicationSecret,
resource,
Expand Down Expand Up @@ -170,7 +170,7 @@ if err != nil {
}

spt, err := adal.NewServicePrincipalTokenFromCertificate(
oauthConfig,
*oauthConfig,
applicationID,
certificate,
rsaPrivateKey,
Expand All @@ -195,7 +195,7 @@ oauthClient := &http.Client{}
// Acquire the device code
deviceCode, err := adal.InitiateDeviceAuth(
oauthClient,
oauthConfig,
*oauthConfig,
applicationID,
resource)
if err != nil {
Expand All @@ -212,7 +212,7 @@ if err != nil {
}

spt, err := adal.NewServicePrincipalTokenFromManualToken(
oauthConfig,
*oauthConfig,
applicationID,
resource,
*token,
Expand All @@ -227,7 +227,7 @@ if (err == nil) {

```Go
spt, err := adal.NewServicePrincipalTokenFromUsernamePassword(
oauthConfig,
*oauthConfig,
applicationID,
username,
password,
Expand All @@ -243,11 +243,11 @@ if (err == nil) {

``` Go
spt, err := adal.NewServicePrincipalTokenFromAuthorizationCode(
oauthConfig,
*oauthConfig,
applicationID,
clientSecret,
authorizationCode,
redirectURI,
authorizationCode,
redirectURI,
resource,
callbacks...)

Expand Down

0 comments on commit 051b144

Please sign in to comment.