diff options
author | r <r@freesoftwareextremist.com> | 2020-04-17 17:19:11 +0000 |
---|---|---|
committer | r <r@freesoftwareextremist.com> | 2020-04-17 17:31:32 +0000 |
commit | 04af1b93dc95d761b4e05a448c9d86ac67623ff6 (patch) | |
tree | 75da80bfb467874b4fd94617f9c7c4cbd3cdbb85 /service/service.go | |
parent | ccdb5ef051bfcc9e96f4b0ce98a32735eb48d1c4 (diff) | |
download | bloat-04af1b93dc95d761b4e05a448c9d86ac67623ff6.tar.gz bloat-04af1b93dc95d761b4e05a448c9d86ac67623ff6.zip |
Add account {,un}subscribe
Diffstat (limited to 'service/service.go')
-rw-r--r-- | service/service.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/service/service.go b/service/service.go index b039849..3a48e77 100644 --- a/service/service.go +++ b/service/service.go @@ -52,6 +52,8 @@ type Service interface { UnMute(ctx context.Context, c *model.Client, id string) (err error) Block(ctx context.Context, c *model.Client, id string) (err error) UnBlock(ctx context.Context, c *model.Client, id string) (err error) + Subscribe(ctx context.Context, c *model.Client, id string) (err error) + UnSubscribe(ctx context.Context, c *model.Client, id string) (err error) SaveSettings(ctx context.Context, c *model.Client, settings *model.Settings) (err error) MuteConversation(ctx context.Context, c *model.Client, id string) (err error) UnMuteConversation(ctx context.Context, c *model.Client, id string) (err error) @@ -839,6 +841,16 @@ func (svc *service) UnBlock(ctx context.Context, c *model.Client, id string) (er return } +func (svc *service) Subscribe(ctx context.Context, c *model.Client, id string) (err error) { + _, err = c.Subscribe(ctx, id) + return +} + +func (svc *service) UnSubscribe(ctx context.Context, c *model.Client, id string) (err error) { + _, err = c.UnSubscribe(ctx, id) + return +} + func (svc *service) SaveSettings(ctx context.Context, c *model.Client, settings *model.Settings) (err error) { |