Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
wuxu92 committed Jul 3, 2024
1 parent 65bc5da commit 0e151f9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions internal/services/cosmos/cosmosdb_account_resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -1557,11 +1557,12 @@ func resourceCosmosDbAccountRead(d *pluginsdk.ResourceData, meta interface{}) er
return fmt.Errorf("flatten key vault uri: %+v", err)
}
if key != nil {
if key.KeyVaultKeyID != nil {
switch {
case key.KeyVaultKeyID != nil:
d.Set("key_vault_key_id", key.KeyVaultKeyID.ID())
} else if key.ManagedHSMKeyID != nil {
case key.ManagedHSMKeyID != nil:
d.Set("managed_hsm_key_id", key.ManagedHSMKeyID.ID())
} else if key.ManagedHSMKeyVersionlessID != nil {
case key.ManagedHSMKeyVersionlessID != nil:
d.Set("managed_hsm_key_id", key.ManagedHSMKeyVersionlessID.ID())
}
}
Expand Down

0 comments on commit 0e151f9

Please sign in to comment.