phabricator/diff/46839
xsanm
tagged this
29 Jan 14:22
Summary: [ENG-10126](https://linear.app/comm/issue/ENG-10126/restore-the-old-userdata-key-during-user-keys-restoration). Alternative is to do it at the end of `getBackupUserKeys` call, however I decided to do it like it because of two reasons: 1. `getBackupUserKeys` is a promise resolved by Rust, we'll need to implement Rust calling `setUserDataKeys` and scheduling on Database thread which is more complex. 2. We might want to call `getBackupUserKeys` just to inspect to return value without setting key and rekeying database, it is better to do it only when needed, directly from restore protcol. Depends on D14268 Test Plan: Tested later in the stack Reviewers: bartek, tomek