From 7c8df92f471af5f40ac126f2bb194722d92228f3 Mon Sep 17 00:00:00 2001 From: Anton Babenko Date: Wed, 26 Jan 2022 12:23:58 +0100 Subject: [PATCH] fix: Fixed redshift_route_table_ids outputs (#739) --- outputs.tf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/outputs.tf b/outputs.tf index ea9e778c2..80c8a2ad8 100644 --- a/outputs.tf +++ b/outputs.tf @@ -250,7 +250,7 @@ output "database_route_table_ids" { output "redshift_route_table_ids" { description = "List of IDs of redshift route tables" - value = try(coalescelist(aws_route_table.redshift[*].id, aws_route_table.public[*].id, aws_route_table.private[*].id), []) + value = length(aws_route_table.redshift[*].id) > 0 ? aws_route_table.redshift[*].id : (var.enable_public_redshift ? aws_route_table.public[*].id : aws_route_table.private[*].id) } output "elasticache_route_table_ids" {