Skip to content

Commit

Permalink
redux types: Make PresenceState inexact, for now.
Browse files Browse the repository at this point in the history
Until Flow v0.111.0 or later, where we'll be when we upgrade to
React Native v0.62.0 (that's issue zulip#3782), exact object types with
indexer properties are broken. See more details in
src/utils/jsonable.js.

In particular, this will help us get userHelpers-test.js
type-checked.
  • Loading branch information
chrisbobbe committed Jul 20, 2020
1 parent 2b3e5d9 commit 6ede62a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/reduxTypes.js
Original file line number Diff line number Diff line change
Expand Up @@ -209,9 +209,9 @@ export type OutboxState = Outbox[];
* @prop (email) - Indexes over all users for which the app has received a
* presence status.
*/
export type PresenceState = {|
export type PresenceState = {
[email: string]: UserPresence,
|};
};

/**
* State with miscellaneous data from the server; our state subtree `realm`.
Expand Down

0 comments on commit 6ede62a

Please sign in to comment.