From 23503be131e9be4d100de03ef480345a64ed15c4 Mon Sep 17 00:00:00 2001 From: wuxu92 Date: Wed, 6 Nov 2024 18:10:59 +0800 Subject: [PATCH] key id trim postfix slash --- internal/customermanagedkeys/key_vault_or_managed_hsm_key.go | 1 + 1 file changed, 1 insertion(+) diff --git a/internal/customermanagedkeys/key_vault_or_managed_hsm_key.go b/internal/customermanagedkeys/key_vault_or_managed_hsm_key.go index 03fc423da624..d5b9deb3585b 100644 --- a/internal/customermanagedkeys/key_vault_or_managed_hsm_key.go +++ b/internal/customermanagedkeys/key_vault_or_managed_hsm_key.go @@ -240,5 +240,6 @@ func FlattenKeyVaultOrManagedHSMID(id string, hsmEnv environments.Api) (*KeyVaul func FlattenKeyVaultOrManagedHSMIDByComponents(baseUri, name, version string, hsmEnv environments.Api) (*KeyVaultOrManagedHSMKey, error) { id := fmt.Sprintf("%s/keys/%s/%s", strings.TrimRight(baseUri, "/"), name, version) + id = strings.TrimSuffix(id, "/") return FlattenKeyVaultOrManagedHSMID(id, hsmEnv) }