Apply suggestions from code review

make queueEvent call async

Co-authored-by: Masen Furer <m_github@0x26.net>
This commit is contained in:
Elijah Ahianyo 2024-06-13 17:29:30 +00:00 committed by GitHub
parent 70b67ed339
commit e74c39cb68
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -135,11 +135,11 @@ export const applyDelta = (state, delta) => {
*
* @returns Adds event to queue and processes it if websocket exits, does nothing otherwise.
*/
export const queueEventIfSocketExists = (events, socket) => {
export const queueEventIfSocketExists = async (events, socket) => {
if (!socket) {
return;
}
queueEvents(events, socket);
await queueEvents(events, socket);
}
/**