File tree Expand file tree Collapse file tree 1 file changed +9
-7
lines changed
Expand file tree Collapse file tree 1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -134,13 +134,15 @@ func RunCommandsPerProject(
134134 ciService .SetStatus (prNumber , "failure" , projectCommands .ProjectName + "/plan" )
135135 return false , false , fmt .Errorf ("failed to run digger plan command. %v" , err )
136136 } else if planPerformed {
137- comment := utils .GetTerraformOutputAsCollapsibleComment ("Plan for **" + projectLock .LockId ()+ "**" , plan )
138- if accumulatePlans {
139- plansToPublish = append (plansToPublish , comment )
140- } else {
141- err = reporter .Report (comment )
142- if err != nil {
143- log .Printf ("Failed to report plan. %v" , err )
137+ if plan != "" {
138+ comment := utils .GetTerraformOutputAsCollapsibleComment ("Plan for **" + projectLock .LockId ()+ "**" , plan )
139+ if accumulatePlans {
140+ plansToPublish = append (plansToPublish , comment )
141+ } else {
142+ err = reporter .Report (comment )
143+ if err != nil {
144+ log .Printf ("Failed to report plan. %v" , err )
145+ }
144146 }
145147 }
146148 ciService .SetStatus (prNumber , "success" , projectCommands .ProjectName + "/plan" )
You can’t perform that action at this time.
0 commit comments