Skip to content

Commit

Permalink
Update data_token.go
Browse files Browse the repository at this point in the history
  • Loading branch information
SvenHamers committed Apr 8, 2021
1 parent 96e5cf1 commit 63f40c7
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions oauth/data_token.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@ func dataSourceTokenRead(ctx context.Context, d *schema.ResourceData, m interfac
clientID := d.Get("client_id").(string)
clientSecret := d.Get("client_secret").(string)
scopes := d.Get("scopes").([]interface{})

val, present := os.LookupEnv("oauth_client_secret")

if present == true {
clientSecret = val
}

opt := &apiClientOpt{
oauth_client_id: clientID,
Expand Down

0 comments on commit 63f40c7

Please sign in to comment.