forked from mtusi2026/mtusi2026lab2
feat(message): store messages in Postgres
This commit is contained in:
@@ -24,8 +24,8 @@ var (
|
||||
)
|
||||
|
||||
type chatQueries interface {
|
||||
CreateChat(ctx context.Context, arg db.CreateChatParams) (db.Chat, error)
|
||||
AddChatMembers(ctx context.Context, arg db.AddChatMembersParams) error
|
||||
CreateChat(ctx context.Context, arg db.CreateChatParams) (db.Chat, error)
|
||||
GetChat(ctx context.Context, arg db.GetChatParams) (db.GetChatRow, error)
|
||||
ListChats(ctx context.Context, arg db.ListChatsParams) ([]db.ListChatsRow, error)
|
||||
}
|
||||
@@ -143,7 +143,7 @@ func (s *ChatService) List(
|
||||
var afterID *uuid.UUID
|
||||
|
||||
if cursor != nil {
|
||||
decoded, err := decodeCursor(*cursor)
|
||||
decoded, err := decodeCursor(*cursor, uuid.Nil)
|
||||
if err != nil {
|
||||
return nil, nil, ErrInvalidCursor
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user