diff options
| author | Harsh Shandilya <me@msfjarvis.dev> | 2021-05-15 12:56:49 +0530 |
|---|---|---|
| committer | Harsh Shandilya <me@msfjarvis.dev> | 2021-05-15 15:40:20 +0530 |
| commit | 7e2eb2425e7b9b6ccb37b7b89f19de3fa7a20c44 (patch) | |
| tree | 6b8a9557ac51b5fab5d2ad7611084cf0de6c57cf /app/src/main/java/dev/msfjarvis/aps/ui/sshkeygen/SshKeyGenActivity.kt | |
| parent | 2fcb285e276594842798be6990b92ba09e733f49 (diff) | |
| download | HardenedPass-7e2eb2425e7b9b6ccb37b7b89f19de3fa7a20c44.tar.gz HardenedPass-7e2eb2425e7b9b6ccb37b7b89f19de3fa7a20c44.zip | |
all: reformat with Spotless again
Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
Diffstat (limited to 'app/src/main/java/dev/msfjarvis/aps/ui/sshkeygen/SshKeyGenActivity.kt')
| -rw-r--r-- | app/src/main/java/dev/msfjarvis/aps/ui/sshkeygen/SshKeyGenActivity.kt | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/app/src/main/java/dev/msfjarvis/aps/ui/sshkeygen/SshKeyGenActivity.kt b/app/src/main/java/dev/msfjarvis/aps/ui/sshkeygen/SshKeyGenActivity.kt index ae420813..cc2cd4c7 100644 --- a/app/src/main/java/dev/msfjarvis/aps/ui/sshkeygen/SshKeyGenActivity.kt +++ b/app/src/main/java/dev/msfjarvis/aps/ui/sshkeygen/SshKeyGenActivity.kt @@ -30,9 +30,15 @@ import kotlinx.coroutines.launch import kotlinx.coroutines.withContext private enum class KeyGenType(val generateKey: suspend (requireAuthentication: Boolean) -> Unit) { - Rsa({ requireAuthentication -> SshKey.generateKeystoreNativeKey(SshKey.Algorithm.Rsa, requireAuthentication) }), - Ecdsa({ requireAuthentication -> SshKey.generateKeystoreNativeKey(SshKey.Algorithm.Ecdsa, requireAuthentication) }), - Ed25519({ requireAuthentication -> SshKey.generateKeystoreWrappedEd25519Key(requireAuthentication) }), + Rsa({ requireAuthentication -> + SshKey.generateKeystoreNativeKey(SshKey.Algorithm.Rsa, requireAuthentication) + }), + Ecdsa({ requireAuthentication -> + SshKey.generateKeystoreNativeKey(SshKey.Algorithm.Ecdsa, requireAuthentication) + }), + Ed25519({ requireAuthentication -> + SshKey.generateKeystoreWrappedEd25519Key(requireAuthentication) + }), } class SshKeyGenActivity : AppCompatActivity() { @@ -50,7 +56,9 @@ class SshKeyGenActivity : AppCompatActivity() { MaterialAlertDialogBuilder(this@SshKeyGenActivity).run { setTitle(R.string.ssh_keygen_existing_title) setMessage(R.string.ssh_keygen_existing_message) - setPositiveButton(R.string.ssh_keygen_existing_replace) { _, _ -> lifecycleScope.launch { generate() } } + setPositiveButton(R.string.ssh_keygen_existing_replace) { _, _ -> + lifecycleScope.launch { generate() } + } setNegativeButton(R.string.ssh_keygen_existing_keep) { _, _ -> finish() } show() } |
