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
F3495542: D6829.id23103.diff
Thu, Dec 19, 9:02 AM
F3495515: D6829.id23018.diff
Thu, Dec 19, 8:58 AM
F3495511: D6829.id22911.diff
Thu, Dec 19, 8:56 AM
F3495507: D6829.id23122.diff
Thu, Dec 19, 8:53 AM
F3495292: D6829.id23094.diff
Thu, Dec 19, 7:58 AM
F3494582: D6829.diff
Thu, Dec 19, 6:14 AM
Unknown Object (File)
Sat, Dec 7, 6:44 AM
Unknown Object (File)
Fri, Nov 22, 1:22 AM
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
Lint Not Applicable
Unit
Tests Not Applicable

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 ↗(On Diff #22912)

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