aboutsummaryrefslogtreecommitdiff
path: root/service/service.go
diff options
context:
space:
mode:
authorr <r@freesoftwareextremist.com>2020-02-02 07:24:06 +0000
committerr <r@freesoftwareextremist.com>2020-02-02 07:24:06 +0000
commit4d9e0af373b3a92d04498070c6fc8f6c197fc9c0 (patch)
treecdd8f8f3b2decbcf85bad4235bb4b914f39bbaad /service/service.go
parentc702a2b501769697576d601875d1db4553eeff12 (diff)
downloadbloat-4d9e0af373b3a92d04498070c6fc8f6c197fc9c0.tar.gz
bloat-4d9e0af373b3a92d04498070c6fc8f6c197fc9c0.zip
Add conversation muting
Diffstat (limited to 'service/service.go')
-rw-r--r--service/service.go14
1 files changed, 14 insertions, 0 deletions
diff --git a/service/service.go b/service/service.go
index ab6261e..043191b 100644
--- a/service/service.go
+++ b/service/service.go
@@ -44,6 +44,8 @@ type Service interface {
Follow(ctx context.Context, c *model.Client, id string) (err error)
UnFollow(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)
}
type service struct {
@@ -848,3 +850,15 @@ func (svc *service) SaveSettings(ctx context.Context, c *model.Client,
session.Settings = *settings
return svc.sessionRepo.Add(session)
}
+
+func (svc *service) MuteConversation(ctx context.Context, c *model.Client,
+ id string) (err error) {
+ _, err = c.MuteConversation(ctx, id)
+ return
+}
+
+func (svc *service) UnMuteConversation(ctx context.Context, c *model.Client,
+ id string) (err error) {
+ _, err = c.UnmuteConversation(ctx, id)
+ return
+}