Skip to content

Commit f8db554

Browse files
authored
regru: update authentication method (#2325)
1 parent 815c61a commit f8db554

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

providers/dns/regru/internal/client.go

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -76,17 +76,14 @@ func (c Client) AddTXTRecord(ctx context.Context, domain, subDomain, content str
7676
func (c Client) doRequest(ctx context.Context, request any, fragments ...string) (*APIResponse, error) {
7777
endpoint := c.baseURL.JoinPath(fragments...)
7878

79-
query := endpoint.Query()
80-
query.Set("username", c.username)
81-
query.Set("password", c.password)
82-
endpoint.RawQuery = query.Encode()
83-
8479
inputData, err := json.Marshal(request)
8580
if err != nil {
8681
return nil, fmt.Errorf("failed to create input data: %w", err)
8782
}
8883

8984
data := url.Values{}
85+
data.Set("username", c.username)
86+
data.Set("password", c.password)
9087
data.Set("input_data", string(inputData))
9188
data.Set("input_format", "json")
9289

0 commit comments

Comments
 (0)