[keyserver] Extract sendPushNotif
Summary:
In D6935 I made a mistake by awaiting inside a loop. In order to await the notifTextsForMessageInfo in parallel, I'm going to extract the code inside the loop into its own async function.
The name sendPushNotif isn't exactly accurate, in the sense that it sends multiple... but sendPushNotifs is already the name of its caller. One alternative I considered was sendPushNotifsForMessage, but that's also slightly inaccurate because there might be multiple new messages. Open to alternatives (or votes for the latter name).
Test Plan:
- In the local dev environment I can test iOS & Android notifs. I tested creating a single message that generates notifs for both iOS and Android
- Flow
Reviewers: michal, marcin, tomek
Reviewed By: tomek
Differential Revision: https://phab.comm.dev/D9175