feat: Introduce muxing for new elements

This commit is contained in:
xvlcwk
2024-02-05 00:19:08 +01:00
committed by chris
parent 81c08dd5a7
commit ce6854b8b6
84 changed files with 912 additions and 790 deletions

View File

@@ -3,8 +3,9 @@ package bitbucket
import (
"encoding/json"
"fmt"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/helper/validation"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
"github.com/hashicorp/terraform-plugin-sdk/v2/helper/validation"
bitbucketTypes "github.com/xvlcwk-terraform/terraform-provider-bitbucketserver/bitbucket/util/types"
"net/url"
"sort"
)
@@ -148,7 +149,7 @@ func dataSourceRepositoryHooksRead(d *schema.ResourceData, m interface{}) error
}
func readRepositoryHooks(m interface{}, project string, repository string, typeFilter string) ([]RepositoryHook, error) {
client := m.(*BitbucketServerProvider).BitbucketClient
client := m.(*bitbucketTypes.BitbucketServerProvider).BitbucketClient
resourceURL := fmt.Sprintf("/rest/api/1.0/projects/%s/repos/%s/settings/hooks",
project,