[lib][native] Only reduce CSAT on setAccessTokenActionType
Summary:
issue: ENG-7428
during both identity registration and log in for both password and wallet users new comm services auth metadata are persisted in CommSecureStore and emitted to JS: https://github.com/CommE2E/comm/blob/master/native/identity-service/identity-service-context-provider.react.js#L329
and https://github.com/CommE2E/comm/blob/master/native/cpp/CommonCpp/NativeModules/CommCoreModule.cpp#L1532-L1537
So we just need to stop removing it with resetUserSpecificState, and stop setting it with all actions but setAccessTokenActionType
We want to keep doing this on web, where we don't have an emitter
Test Plan:
- Tested that on web CSAT is cleared on logout, and is present when user is logged in
- Tested that on logout CSAT is set to an empty string on native
- Tested that on login/register CSAT is set to a non empty string on native
- Tested that if setNewSessionActionType with cookieInvalidated is dispatched, then the user is logged out and the CSAT is cleared
Reviewers: michal, marcin, tomek, ashoat
Reviewed By: ashoat
Subscribers: varun, ashoat
Differential Revision: https://phab.comm.dev/D11395