Skip to content

Commit e763ab1

Browse files
committed
event: Fix things in new API event types that clearly aren't right.
These aren't yet used anywhere -- they were salvaged a few commits ago from src/types.js to seed this new file. So it's natural that there are places they're wrong or incomplete. Fix some of those; mark others safely with `empty` to prevent accidentally using them before they're reviewed and ready.
1 parent ab4a91a commit e763ab1

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/api/eventTypes.js

+5-5
Original file line numberDiff line numberDiff line change
@@ -58,22 +58,22 @@ export type HeartbeatEvent = {|
5858

5959
export type MessageEvent = {|
6060
...EventCommon,
61-
type: 'message',
61+
type: empty, // 'message' -- TODO fill in rest
6262
|};
6363

6464
export type PresenceEvent = {|
6565
...EventCommon,
66-
type: 'message',
66+
type: 'presence',
6767
email: string,
68-
presence: { [client: string]: ClientPresence },
6968
server_timestamp: number,
69+
presence: { [client: string]: ClientPresence },
7070
|};
7171

7272
export type UpdateMessageFlagsEvent = {|
7373
...EventCommon,
7474
type: 'update_message_flags',
75+
operation: 'add' | 'remove',
76+
flag: empty, // TODO fill in
7577
all: boolean,
76-
flag: 'read' | '???',
7778
messages: number[],
78-
operation: 'add' | '???',
7979
|};

0 commit comments

Comments
 (0)