From f68d72ae0eb2eb6c15cd225c1a3b9185aaa20e3f Mon Sep 17 00:00:00 2001 From: r Date: Sun, 15 Dec 2019 17:37:58 +0000 Subject: Add notification support --- service/logging.go | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'service/logging.go') diff --git a/service/logging.go b/service/logging.go index 3a95a94..aa1da68 100644 --- a/service/logging.go +++ b/service/logging.go @@ -77,6 +77,14 @@ func (s *loggingService) ServeThreadPage(ctx context.Context, client io.Writer, return s.Service.ServeThreadPage(ctx, client, c, id, reply) } +func (s *loggingService) ServeNotificationPage(ctx context.Context, client io.Writer, c *mastodon.Client, maxID string, minID string) (err error) { + defer func(begin time.Time) { + s.logger.Printf("method=%v, max_id=%v, min_id=%v, took=%v, err=%v\n", + "ServeNotificationPage", maxID, minID, time.Since(begin), err) + }(time.Now()) + return s.Service.ServeNotificationPage(ctx, client, c, maxID, minID) +} + func (s *loggingService) Like(ctx context.Context, client io.Writer, c *mastodon.Client, id string) (err error) { defer func(begin time.Time) { s.logger.Printf("method=%v, id=%v, took=%v, err=%v\n", -- cgit v1.2.3