aboutsummaryrefslogtreecommitdiffhomepage
path: root/vendor/github.com/hashicorp/terraform/config/interpolate_walk.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/hashicorp/terraform/config/interpolate_walk.go')
-rw-r--r--vendor/github.com/hashicorp/terraform/config/interpolate_walk.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/vendor/github.com/hashicorp/terraform/config/interpolate_walk.go b/vendor/github.com/hashicorp/terraform/config/interpolate_walk.go
index 66a677d..ce33ab1 100644
--- a/vendor/github.com/hashicorp/terraform/config/interpolate_walk.go
+++ b/vendor/github.com/hashicorp/terraform/config/interpolate_walk.go
@@ -7,6 +7,7 @@ import (
7 7
8 "github.com/hashicorp/hil" 8 "github.com/hashicorp/hil"
9 "github.com/hashicorp/hil/ast" 9 "github.com/hashicorp/hil/ast"
10 "github.com/hashicorp/terraform/config/hcl2shim"
10 "github.com/mitchellh/reflectwalk" 11 "github.com/mitchellh/reflectwalk"
11) 12)
12 13
@@ -160,7 +161,7 @@ func (w *interpolationWalker) Primitive(v reflect.Value) error {
160 if w.loc == reflectwalk.SliceElem { 161 if w.loc == reflectwalk.SliceElem {
161 switch typedReplaceVal := replaceVal.(type) { 162 switch typedReplaceVal := replaceVal.(type) {
162 case string: 163 case string:
163 if typedReplaceVal == UnknownVariableValue { 164 if typedReplaceVal == hcl2shim.UnknownVariableValue {
164 remove = true 165 remove = true
165 } 166 }
166 case []interface{}: 167 case []interface{}:
@@ -168,7 +169,7 @@ func (w *interpolationWalker) Primitive(v reflect.Value) error {
168 remove = true 169 remove = true
169 } 170 }
170 } 171 }
171 } else if replaceVal == UnknownVariableValue { 172 } else if replaceVal == hcl2shim.UnknownVariableValue {
172 remove = true 173 remove = true
173 } 174 }
174 175
@@ -224,7 +225,7 @@ func (w *interpolationWalker) replaceCurrent(v reflect.Value) {
224func hasUnknownValue(variable []interface{}) bool { 225func hasUnknownValue(variable []interface{}) bool {
225 for _, value := range variable { 226 for _, value := range variable {
226 if strVal, ok := value.(string); ok { 227 if strVal, ok := value.(string); ok {
227 if strVal == UnknownVariableValue { 228 if strVal == hcl2shim.UnknownVariableValue {
228 return true 229 return true
229 } 230 }
230 } 231 }