feat: Save last logged account public key after authentication for improved user experience

This commit is contained in:
k1ngsterr1
2026-01-12 17:16:44 +05:00
parent 67e99901be
commit 8aa17383cf
6 changed files with 117 additions and 27 deletions

View File

@@ -494,8 +494,6 @@ fun SetPasswordScreen(
accountManager.saveAccount(account)
accountManager.setCurrentAccount(keyPair.publicKey)
// Save as last logged account for next time
accountManager.setLastLoggedPublicKey(keyPair.publicKey)
// 🔌 Connect to server and authenticate
val privateKeyHash = CryptoManager.generatePrivateKeyHash(keyPair.privateKey)

View File

@@ -587,8 +587,6 @@ fun UnlockScreen(
ProtocolManager.authenticate(account.publicKey, privateKeyHash)
accountManager.setCurrentAccount(account.publicKey)
// Save as last logged account for next time
accountManager.setLastLoggedPublicKey(account.publicKey)
onUnlocked(decryptedAccount)
} catch (e: Exception) {