summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxuzhang3 <Zhangxu894765>2022-10-24 17:14:44 +0800
committerxuzhang3 <Zhangxu894765>2022-10-24 17:14:44 +0800
commit54ca015dbbc9cc231ebfdf7eb3bfa293e5a14776 (patch)
tree1aff6565d291073b890192ac12acee0f306d885c
parentd675bdfccd893a4fb9f4d4457b0a5c94717e6f8f (diff)
rename local val
-rw-r--r--azuredevops/internal/service/serviceendpoint/resource_serviceendpoint_artifactory.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/azuredevops/internal/service/serviceendpoint/resource_serviceendpoint_artifactory.go b/azuredevops/internal/service/serviceendpoint/resource_serviceendpoint_artifactory.go
index 90f1b65d..c2156417 100644
--- a/azuredevops/internal/service/serviceendpoint/resource_serviceendpoint_artifactory.go
+++ b/azuredevops/internal/service/serviceendpoint/resource_serviceendpoint_artifactory.go
@@ -140,11 +140,11 @@ func flattenServiceEndpointArtifactory(d *schema.ResourceData, serviceEndpoint *
if strings.EqualFold(*serviceEndpoint.Authorization.Scheme, "Token") {
auth := make(map[string]interface{})
if x, ok := d.GetOk("authentication_token"); ok {
- authList := x.([]interface{})[0].(map[string]interface{})
- if len(authList) > 0 {
- newHash, hashKey := tfhelper.HelpFlattenSecretNested(d, "authentication_token", authList, "token")
+ authMap := x.([]interface{})[0].(map[string]interface{})
+ if len(authMap) > 0 {
+ newHash, hashKey := tfhelper.HelpFlattenSecretNested(d, "authentication_token", authMap, "token")
auth[hashKey] = newHash
- auth["token"] = authList["token"]
+ auth["token"] = authMap["token"]
}
}
d.Set("authentication_token", []interface{}{auth})