Page MenuHomePhabricator

[lib] add legal policies list
ClosedPublic

Authored by kamil on Oct 6 2022, 3:09 AM.
Tags
None
Referenced Files
F3489898: D5306.diff
Wed, Dec 18, 2:06 PM
Unknown Object (File)
Tue, Nov 26, 5:06 PM
Unknown Object (File)
Tue, Nov 26, 5:06 PM
Unknown Object (File)
Tue, Nov 26, 5:06 PM
Unknown Object (File)
Sun, Nov 24, 2:42 PM
Unknown Object (File)
Sun, Nov 24, 2:42 PM
Unknown Object (File)
Sun, Nov 24, 2:42 PM
Unknown Object (File)
Sun, Nov 24, 2:42 PM

Details

Summary

Add hardcoded list of policies that users will need to acknowledge.

If any new policy will be introduced only operation needed will be updating this object.

I decided to use object instead of the only array with string values, maybe in future there will be a need to distinguish between them, make some operations only on one and it will be easier to access (eg. now on running a script and choosing which policy requires re-acknowledge it can be based on object prop).

Test Plan

yarn flow check

Diff Detail

Repository
rCOMM Comm
Branch
track-acknowledgments
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

kamil held this revision as a draft.
kamil edited the test plan for this revision. (Show Details)
kamil added a reviewer: atul.
kamil published this revision for review.Oct 6 2022, 4:49 AM

Please address nit before landing

lib/facts/policies.js
2

Nit: can you add a newline below // @flow, for consistency with the rest of the codebase?

This revision is now accepted and ready to land.Oct 6 2022, 6:11 AM
marcin added a reviewer: tomek.
This revision now requires review to proceed.Oct 11 2022, 11:30 AM
atul added inline comments.
lib/facts/policies.js
5

Should we add a month/year here? Figure we'll probably change this at some point in the future.

Maybe

tosAndPrivacyPolicyOct2022 = 'TERMS_OF_USE_AND_PRIVACY_POLICY_OCT_2022',

?

lib/facts/policies.js
5

As designed right now, that's handled by a separate column in the table

add new line below // @flow

lib/facts/policies.js
5

Should we add a month/year here? Figure we'll probably change this at some point in the future.

Maybe

tosAndPrivacyPolicyOct2022 = 'TERMS_OF_USE_AND_PRIVACY_POLICY_OCT_2022',

?

thanks for suggestion @atul, but you are talking about second solution described here while we decided to stick to first one

This revision is now accepted and ready to land.Oct 12 2022, 3:09 AM
This revision was automatically updated to reflect the committed changes.