Skip to content

Commit 7604cb8

Browse files
Apply suggestions from code review
Co-authored-by: Melissa Greenbaum <[email protected]>
1 parent 42cb1ad commit 7604cb8

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

main.tf

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ resource "aws_db_subnet_group" "this" {
3636
################################################################################
3737

3838
locals {
39-
use_master_password = var.is_primary_cluster && !var.manage_master_user_password && var.global_cluster_identifier == null
39+
use_master_password = var.is_primary_cluster && !local.use_managed_master_password
4040
use_managed_master_password = var.manage_master_user_password && var.global_cluster_identifier == null
4141
}
4242

@@ -585,12 +585,12 @@ resource "aws_rds_shard_group" "this" {
585585
tags = merge(var.tags, var.shard_group.tags)
586586

587587
dynamic "timeouts" {
588-
for_each = var.shard_group != null ? [var.shard_group] : []
588+
for_each = var.shard_group.timeouts != null ? [var.shard_group.timeouts] : []
589589

590590
content {
591-
create = each.value.create
592-
update = each.value.update
593-
delete = each.value.delete
591+
create = timeouts.value.create
592+
update = timeouts.value.update
593+
delete = timeouts.value.delete
594594
}
595595
}
596596
}

modules/dsql/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ resource "aws_dsql_cluster_peering" "this" {
4141
for_each = var.timeouts != null ? [var.timeouts] : []
4242

4343
content {
44-
create = each.value.create
44+
create = timeouts.value.create
4545
}
4646
}
4747
}

0 commit comments

Comments
 (0)