Page MenuHomePhabricator

[keyserver] convert existing logic for building userPushInfoPromises to an async function called generateNotifUserInfoPromise
ClosedPublic

Authored by ginsu on Feb 21 2023, 10:46 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Mar 15, 9:20 PM
Unknown Object (File)
Tue, Mar 5, 10:05 PM
Unknown Object (File)
Mon, Mar 4, 6:12 PM
Unknown Object (File)
Sat, Mar 2, 1:30 PM
Unknown Object (File)
Feb 21 2024, 10:20 PM
Unknown Object (File)
Feb 21 2024, 1:50 PM
Unknown Object (File)
Feb 21 2024, 1:49 PM
Unknown Object (File)
Feb 21 2024, 1:49 PM
Subscribers

Details

Summary

The logic for building userPushInfoPromise will be really simlar when we build userRescindInfoPromise so I built generateNotifUserInfoPromise to reuse this logic in a subseqent diff


Depends on D6307
Linear Task: ENG-2644

Test Plan

flow and please see video showing no regressions with the notifications.

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

ashoat requested changes to this revision.Feb 22 2023, 11:09 AM
ashoat added inline comments.
keyserver/src/creators/message-creator.js
428

Why isn't this an async function? If you're returning a Promise, you should pretty much always use await / async

This revision now requires changes to proceed.Feb 22 2023, 11:09 AM

address ashoat's comments

ashoat requested changes to this revision.Feb 23 2023, 12:02 PM

You need to do more than just add async. I don't think you have a full understanding of async/await here

This revision now requires changes to proceed.Feb 23 2023, 12:02 PM

address ashoat's comments

ginsu retitled this revision from [keyserver] convert existing logic for building userPushInfoPromises to an IIFE called generateNotifUserInfoPromise to [keyserver] convert existing logic for building userPushInfoPromises to an async function called generateNotifUserInfoPromise.Feb 24 2023, 4:55 PM
ashoat removed 1 blocking reviewer(s): atul.
This revision is now accepted and ready to land.Feb 26 2023, 5:38 AM