If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Problem
The methods in permissions.js file should be asynchronous. They kind of already are if you look at the code, since data is coming from Onyx, but the methods themselves as synchronous, which does not align with how the data is loaded, so there are possible race conditions.
Solution
Change all places where permissions is used to instead subscribe to the ONYXKEYS.BETAS onyx key and call permissions methods passing the betas it got from onyx (see this comment)
Upwork posting - https://www.upwork.com/jobs/~01f29f2d2fa738d842
/cc @tgolen @marcaaron
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Problem
The methods in permissions.js file should be asynchronous. They kind of already are if you look at the code, since data is coming from Onyx, but the methods themselves as synchronous, which does not align with how the data is loaded, so there are possible race conditions.
Solution
Change all places where permissions is used to instead subscribe to the
ONYXKEYS.BETASonyx key and call permissions methods passing the betas it got from onyx (see this comment)Upwork posting - https://www.upwork.com/jobs/~01f29f2d2fa738d842
/cc @tgolen @marcaaron