File tree Expand file tree Collapse file tree 2 files changed +10
-4
lines changed Expand file tree Collapse file tree 2 files changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -13,6 +13,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1313 support for the ` enable_token_revocation ` in the ` aws_cognito_user_pool_client `
1414 resource.
1515
16+ ### Fixed
17+
18+ - Fixed implementation of ` token_validity_units ` block.
19+
1620## [ 0.8.0]
1721
1822### BREAKING
Original file line number Diff line number Diff line change @@ -233,16 +233,18 @@ resource "aws_cognito_user_pool_client" "client" {
233233 id_token_validity = each. value . id_token_validity
234234
235235 dynamic "token_validity_units" {
236- for_each = length ( each. value . token_validity_units ) > 0 ? [true ] : []
236+ for_each = each. value . token_validity_units != null ? [each . value . token_validity_units ] : []
237237
238238 content {
239- refresh_token = each . value . token_validity_units . refresh_token
240- access_token = each . value . token_validity_units . access_token
241- id_token = each . value . token_validity_units . id_token
239+ refresh_token = try (token_validity_units . value . refresh_token , null )
240+ access_token = try (token_validity_units . value . access_token , null )
241+ id_token = try (token_validity_units . value . id_token , null )
242242 }
243243 }
244+
244245 enable_token_revocation = each. value . enable_token_revocation
245246}
247+
246248resource "aws_cognito_user_pool_domain" "domain" {
247249 count = var. module_enabled && var. domain != null ? 1 : 0
248250
You can’t perform that action at this time.
0 commit comments