[native] implement hook for restore
Summary:
ENG-8195.
Implementing a hook for user restore, similar to the password/wallet user login.
Depends on D14082
Test Plan:
- Use this hook in LogInPanel instead of usePasswordLogIn.
- Add a bunch of logs.
- Register a new Account and add a different user as a friend.
- Log out using v2.
- Log in (which executed restore).
- Look at logs - all steps passed.
- The user is visually logged in, and everything works.
- On other user observer logs, the device list is updated, but it's not passing validation (which is expected because of D14079). After D14079 is deployed, validation should pass.
EDIT: Tested after Identity deploy, it works!
Reviewers: bartek, tomek, varun
Reviewed By: tomek
Subscribers: ashoat
Differential Revision: https://phab.comm.dev/D14083