-
Notifications
You must be signed in to change notification settings - Fork 782
Special text for re-verification after update #8462
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a remark, else LGTM.
(Tests seem to be failing).
@@ -170,6 +171,19 @@ class MainActivity : VectorBaseActivity<ActivityMainBinding>(), UnlockedActivity | |||
} | |||
|
|||
private fun handleAppStarted() { | |||
// On the first run with rust crypto this would be false | |||
if (!vectorPreferences.isOnRustCrypto()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you need to test BuildConfig.FLAVOR == "rustCrypto"
also:
if (!vectorPreferences.isOnRustCrypto()) { | |
if (BuildConfig.FLAVOR == "rustCrypto" && !vectorPreferences.isOnRustCrypto()) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's ok now, isOnRustCrypto will pass to true only if you run once on the new rust flavor.
If you have a logged in session before that it will store that you had legacy data, and in the check for the popup we do that check:
vectorPreferences.isOnRustCrypto() && vectorPreferences.hadExistingLegacyData()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK. My point was that the code in the if block will run every time on the KotlinCrypto version. Not a big deal of course.
} | ||
|
||
if (BuildConfig.FLAVOR == "rustCrypto") { | ||
vectorPreferences.setIsOnRustCrypto(true) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line could then be moved at the end of the previous if
block.
SonarCloud Quality Gate failed. |
Type of change
Content
Fixes #8445
If you have a read only device (not all secrets available):

After the migration to rust you will need to re-verify, the text is updated like this in this case

Motivation and context
Screenshots / GIFs
Tests
Tested devices
Checklist