From 7e28e2d84614a86416fd8a9991129670173d4125 Mon Sep 17 00:00:00 2001 From: Austin Valle Date: Fri, 17 May 2024 09:11:33 -0400 Subject: [PATCH] tfjson: Update `Complete` to a pointer value for older Terraform versions (#131) --- plan.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plan.go b/plan.go index 67a5b6e..d861898 100644 --- a/plan.go +++ b/plan.go @@ -66,7 +66,10 @@ type Plan struct { // Complete indicates that all resources have successfully planned changes. // This will be false if there are DeferredChanges or if the -target flag is used. - Complete bool `json:"complete,omitempty"` + // + // Complete was introduced in Terraform 1.8 and will be nil for all previous + // Terraform versions. + Complete *bool `json:"complete,omitempty"` // The change operations for outputs within this plan. OutputChanges map[string]*Change `json:"output_changes,omitempty"`