diff options
author | r <r@freesoftwareextremist.com> | 2022-12-17 06:58:00 +0000 |
---|---|---|
committer | r <r@freesoftwareextremist.com> | 2022-12-17 06:58:47 +0000 |
commit | 9816045c21957bfda6760ca058eaae97901e3b63 (patch) | |
tree | 9a3f140a02865af642d157e4c01b58cbd18874c2 | |
parent | 6002284c5af53c3c0aed74f9f56cea348f8740d9 (diff) | |
download | bloat-9816045c21957bfda6760ca058eaae97901e3b63.tar.gz bloat-9816045c21957bfda6760ca058eaae97901e3b63.zip |
Pass with_relationships param for accounts
-rw-r--r-- | mastodon/accounts.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/mastodon/accounts.go b/mastodon/accounts.go index dbd0a48..540adb2 100644 --- a/mastodon/accounts.go +++ b/mastodon/accounts.go @@ -56,7 +56,9 @@ type AccountSource struct { // GetAccount return Account. func (c *Client) GetAccount(ctx context.Context, id string) (*Account, error) { var account Account - err := c.doAPI(ctx, http.MethodGet, fmt.Sprintf("/api/v1/accounts/%s", url.PathEscape(string(id))), nil, &account, nil) + params := url.Values{} + params.Set("with_relationships", strconv.FormatBool(true)) + err := c.doAPI(ctx, http.MethodGet, fmt.Sprintf("/api/v1/accounts/%s", url.PathEscape(string(id))), params, &account, nil) if err != nil { return nil, err } |