Update timers whenever we mark messages read

This commit is contained in:
Scott Nonnenberg 2021-07-19 13:45:18 -07:00 committed by GitHub
parent cd35a29638
commit 7761d83055
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 70 additions and 150 deletions

View file

@ -293,6 +293,14 @@ export type DataInterface = {
options?: { limit?: number }
) => Promise<Array<ConversationType>>;
saveMessage: (
data: MessageType,
options?: { forceSave?: boolean }
) => Promise<string>;
saveMessages: (
arrayOfMessages: Array<MessageType>,
options?: { forceSave?: boolean }
) => Promise<void>;
getMessageCount: (conversationId?: string) => Promise<number>;
hasUserInitiatedMessages: (conversationId: string) => Promise<boolean>;
getAllMessageIds: () => Promise<Array<string>>;
@ -487,14 +495,6 @@ export type ServerInterface = DataInterface & {
conversationId: string,
options?: { limit?: number }
) => Promise<Array<SearchResultMessageType>>;
saveMessage: (
data: MessageType,
options: { forceSave?: boolean }
) => Promise<string>;
saveMessages: (
arrayOfMessages: Array<MessageType>,
options: { forceSave?: boolean }
) => Promise<void>;
updateConversation: (data: ConversationType) => Promise<void>;
// For testing only
@ -599,14 +599,6 @@ export type ClientInterface = DataInterface & {
ids: Array<string>,
options: { Message: typeof MessageModel }
) => Promise<void>;
saveMessage: (
data: MessageType,
options: { forceSave?: boolean; Message: typeof MessageModel }
) => Promise<string>;
saveMessages: (
arrayOfMessages: Array<MessageType>,
options: { forceSave?: boolean; Message: typeof MessageModel }
) => Promise<void>;
searchMessages: (
query: string,
options?: { limit?: number }