From 230513d61b7f31094368d3dea9bd808d318238f0 Mon Sep 17 00:00:00 2001 From: Gordon <1432970085@qq.com> Date: Wed, 14 Jun 2023 16:30:56 +0800 Subject: [PATCH] fix: msg rpc panic --- internal/rpc/msg/as_read.go | 2 +- internal/rpc/msg/server.go | 5 ----- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/internal/rpc/msg/as_read.go b/internal/rpc/msg/as_read.go index 19c97fb19..8bca14c7f 100644 --- a/internal/rpc/msg/as_read.go +++ b/internal/rpc/msg/as_read.go @@ -35,7 +35,7 @@ func (m *msgServer) GetConversationsHasReadAndMaxSeq(ctx context.Context, req *m return resp, nil } -func (m *msgServer) SetConversationHasReadMaxSeq(ctx context.Context, req *msg.SetConversationHasReadSeqReq) (resp *msg.SetConversationHasReadSeqResp, err error) { +func (m *msgServer) SetConversationHasReadSeq(ctx context.Context, req *msg.SetConversationHasReadSeqReq) (resp *msg.SetConversationHasReadSeqResp, err error) { maxSeq, err := m.MsgDatabase.GetMaxSeq(ctx, req.ConversationID) if err != nil { return diff --git a/internal/rpc/msg/server.go b/internal/rpc/msg/server.go index 94510771c..c2b30191e 100644 --- a/internal/rpc/msg/server.go +++ b/internal/rpc/msg/server.go @@ -34,11 +34,6 @@ type msgServer struct { notificationSender *rpcclient.NotificationSender } -func (m *msgServer) SetConversationHasReadSeq(ctx context.Context, req *msg.SetConversationHasReadSeqReq) (*msg.SetConversationHasReadSeqResp, error) { - //TODO implement me - panic("implement me") -} - func (m *msgServer) addInterceptorHandler(interceptorFunc ...MessageInterceptorFunc) { m.Handlers = append(m.Handlers, interceptorFunc...) }