mirror of
https://github.com/matrix-org/gomatrix
synced 2025-05-12 10:41:44 +00:00
Add missing User-Interactive fields. Only add access_token if one was given.
This commit is contained in:
parent
4517ecd6ed
commit
831dfd27a6
2 changed files with 8 additions and 3 deletions
|
@ -75,7 +75,9 @@ func (cli *Client) BuildBaseURL(urlPath ...string) string {
|
|||
parts = append(parts, urlPath...)
|
||||
hsURL.Path = path.Join(parts...)
|
||||
query := hsURL.Query()
|
||||
query.Set("access_token", cli.AccessToken)
|
||||
if cli.AccessToken != "" {
|
||||
query.Set("access_token", cli.AccessToken)
|
||||
}
|
||||
hsURL.RawQuery = query.Encode()
|
||||
return hsURL.String()
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue