Use gomatrixserverlib.Client for three-PID invites

This commit is contained in:
Neil Alexander 2022-05-05 11:11:36 +01:00
parent 06e23bb2ce
commit b48842cc6e
No known key found for this signature in database
GPG key ID: A02A2019A2BB0944

View file

@ -231,7 +231,7 @@ func queryIDServerStoreInvite(
profile = &authtypes.Profile{}
}
client := http.Client{}
client := gomatrixserverlib.NewClient()
data := url.Values{}
data.Add("medium", body.Medium)
@ -253,7 +253,7 @@ func queryIDServerStoreInvite(
}
req.Header.Add("Content-Type", "application/x-www-form-urlencoded")
resp, err := client.Do(req.WithContext(ctx))
resp, err := client.DoHTTPRequest(ctx, req)
if err != nil {
return nil, err
}