diff options
author | r <r@freesoftwareextremist.com> | 2019-12-20 18:30:20 +0000 |
---|---|---|
committer | r <r@freesoftwareextremist.com> | 2019-12-20 18:30:20 +0000 |
commit | a1f49af1d93bccdd56d4538b149884418bd2ca2c (patch) | |
tree | add621fe17d9dbcf3625bcc7de1738ea8c89bc9f /service/auth.go | |
parent | 3d1e4cfa4c17eea9a64b8672df769c540fefdaeb (diff) | |
download | bloat-a1f49af1d93bccdd56d4538b149884418bd2ca2c.tar.gz bloat-a1f49af1d93bccdd56d4538b149884418bd2ca2c.zip |
Add user page and follow/unfollow calls
Diffstat (limited to 'service/auth.go')
-rw-r--r-- | service/auth.go | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/service/auth.go b/service/auth.go index 38c0a43..2b6fdd6 100644 --- a/service/auth.go +++ b/service/auth.go @@ -119,6 +119,14 @@ func (s *authService) ServeNotificationPage(ctx context.Context, client io.Write return s.Service.ServeNotificationPage(ctx, client, c, maxID, minID) } +func (s *authService) ServeUserPage(ctx context.Context, client io.Writer, c *mastodon.Client, id string, maxID string, minID string) (err error) { + c, err = s.getClient(ctx) + if err != nil { + return + } + return s.Service.ServeUserPage(ctx, client, c, id, maxID, minID) +} + func (s *authService) Like(ctx context.Context, client io.Writer, c *mastodon.Client, id string) (err error) { c, err = s.getClient(ctx) if err != nil { @@ -158,3 +166,19 @@ func (s *authService) PostTweet(ctx context.Context, client io.Writer, c *mastod } return s.Service.PostTweet(ctx, client, c, content, replyToID, files) } + +func (s *authService) Follow(ctx context.Context, client io.Writer, c *mastodon.Client, id string) (err error) { + c, err = s.getClient(ctx) + if err != nil { + return + } + return s.Service.Follow(ctx, client, c, id) +} + +func (s *authService) UnFollow(ctx context.Context, client io.Writer, c *mastodon.Client, id string) (err error) { + c, err = s.getClient(ctx) + if err != nil { + return + } + return s.Service.UnFollow(ctx, client, c, id) +} |