From 8a062b92b966196f93ca505113470dcc5d6f4568 Mon Sep 17 00:00:00 2001 From: Matt Kubilus <39499390+mkubilus@users.noreply.github.com> Date: Thu, 5 May 2022 11:24:58 -0400 Subject: [PATCH] fix: Corrects errors when plan contains no pricing changes (#8) --- modules/pricing/state_and_plan_content_from_json.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/pricing/state_and_plan_content_from_json.tf b/modules/pricing/state_and_plan_content_from_json.tf index 7ccf114..13d5509 100644 --- a/modules/pricing/state_and_plan_content_from_json.tf +++ b/modules/pricing/state_and_plan_content_from_json.tf @@ -55,7 +55,7 @@ locals { instances_map = local.input_type == "plan" ? local.normalized_plan_instances : local.normalized_state_instances - instances_stripped_keys = local.input_type == "empty" ? [] : concat([ + instances_stripped_keys = local.input_type == "empty" || length(local.instances_map) == 0 ? [] : concat([ for k, v in local.instances_map : setproduct([k], keys(v)) ]...)