]> git.immae.eu Git - github/fretlink/terraform-provider-statuscake.git/blobdiff - vendor/github.com/hashicorp/hcl2/hcldec/public.go
Upgrade to 0.12
[github/fretlink/terraform-provider-statuscake.git] / vendor / github.com / hashicorp / hcl2 / hcldec / public.go
index 5d1f10a3db449a6721367ed635bafca56f194e58..3c803632d93f7c6a8f19137f83a765b382253bca 100644 (file)
@@ -65,7 +65,10 @@ func ChildBlockTypes(spec Spec) map[string]Spec {
        visit = func(s Spec) {
                if bs, ok := s.(blockSpec); ok {
                        for _, blockS := range bs.blockHeaderSchemata() {
-                               ret[blockS.Type] = bs.nestedSpec()
+                               nested := bs.nestedSpec()
+                               if nested != nil { // nil can be returned to dynamically opt out of this interface
+                                       ret[blockS.Type] = nested
+                               }
                        }
                }