HomePhabricator
Diffusion Comm 131f99f35a9c

[native] Introduce `useStaffCanSee()`

Tags
None
Referenced Files
F209770: 42f5c5.png
Nov 1 2022, 10:33 AM
File Not Attached
Subscribers
None

Description

[native] Introduce useStaffCanSee()

Summary:
Context: https://linear.app/comm/issue/ENG-2134/have-a-flag-that-indicates-whether-the-build-is-a-staff-release

Utility that tells us whether we're running a debug build (__DEV__) and/or are "staff" (isStaff(state.currentUserInfo.id)) and/or are on a staff release (isStaffRelease).

In subsequent diff will use this function where isStaff || __DEV__ checks were used in the past.

Test Plan:
Logged values and they were as expected:

42f5c5.png (1×1 px, 433 KB)

Reviewers: tomek, marcin, varun, ashoat

Reviewed By: ashoat

Subscribers: ashoat, abosh

Differential Revision: https://phab.comm.dev/D5498

Details

Provenance
atulAuthored on Nov 1 2022, 10:31 AM
Reviewer
ashoat
Differential Revision
D5498: [native] Introduce `useStaffCanSee()`
Parents
rCOMMe4e42e88c56c: [keyserver] added siwe packages
Branches
Unknown
Tags
Unknown