Send all notifications received by backgrounded app to JS at once
Summary:
Previously for each notification received by backgrounded app we sent separate JS event so that it could be persisted in redux and SQLite. However there was
no reason not to send one JS event with array of all messages. It can potentially help the issue:
https://linear.app/comm/issue/ENG-5147/messageinfos-from-notifs-take-too-long-to-import-on-ios-start#comment-a2fb0774
Test Plan:
- Build iOS app.
- Background it.
- Send multiple messages.
- Kill the keyserver.
- Bring the app to the foreground again.
- Ensure all messages are available in the relevant thread(s) even the keyserver is not running.
Reviewers: tomek, bartek, michal
Reviewed By: tomek
Subscribers: ashoat, wyilio
Differential Revision: https://phab.comm.dev/D9429