small cleanup
This commit is contained in:
parent
74cae47902
commit
72a412904d
|
@ -371,7 +371,7 @@ internal class DefaultSharedSecretStorageService @Inject constructor(
|
|||
callback.onFailure(SharedSecretStorageError.BadKeyFormat)
|
||||
}
|
||||
cryptoCoroutineScope.launch(coroutineDispatchers.main) {
|
||||
kotlin.runCatching {
|
||||
runCatching {
|
||||
// decrypt from recovery key
|
||||
withOlmDecryption { olmPkDecryption ->
|
||||
olmPkDecryption.setPrivateKey(keySpec.privateKey)
|
||||
|
@ -390,7 +390,7 @@ internal class DefaultSharedSecretStorageService @Inject constructor(
|
|||
callback.onFailure(SharedSecretStorageError.BadKeyFormat)
|
||||
}
|
||||
cryptoCoroutineScope.launch(coroutineDispatchers.main) {
|
||||
kotlin.runCatching {
|
||||
runCatching {
|
||||
decryptAesHmacSha2(keySpec, name, secretContent)
|
||||
}.foldToCallback(callback)
|
||||
}
|
||||
|
|
|
@ -126,7 +126,7 @@ class KeyRequestHandler @Inject constructor(
|
|||
// can we get more info on this device?
|
||||
session?.cryptoService()?.getMyDevicesInfo()?.firstOrNull { it.deviceId == deviceId }?.let {
|
||||
postAlert(context, userId, deviceId, true, deviceInfo, it)
|
||||
} ?: kotlin.run {
|
||||
} ?: run {
|
||||
postAlert(context, userId, deviceId, true, deviceInfo)
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -139,7 +139,7 @@ class BootstrapCrossSigningTask @Inject constructor(
|
|||
null,
|
||||
it
|
||||
)
|
||||
} ?: kotlin.run {
|
||||
} ?: run {
|
||||
ssssService.generateKey(
|
||||
UUID.randomUUID().toString(),
|
||||
params.keySpec,
|
||||
|
|
|
@ -301,7 +301,7 @@ class BootstrapSharedViewModel @AssistedInject constructor(
|
|||
// =======================================
|
||||
private fun saveRecoveryKeyToUri(os: OutputStream) = withState { state ->
|
||||
viewModelScope.launch(Dispatchers.IO) {
|
||||
kotlin.runCatching {
|
||||
runCatching {
|
||||
os.use {
|
||||
os.write((state.recoveryKeyCreationInfo?.recoveryKey?.formatRecoveryKey() ?: "").toByteArray())
|
||||
}
|
||||
|
|
|
@ -72,7 +72,7 @@ abstract class BottomSheetVerificationEmojisItem : VectorEpoxyModel<BottomSheetV
|
|||
view.findViewById<TextView>(R.id.item_emoji_tv).isVisible = false
|
||||
view.findViewById<ImageView>(R.id.item_emoji_image).isVisible = true
|
||||
view.findViewById<ImageView>(R.id.item_emoji_image).setImageDrawable(ContextCompat.getDrawable(view.context, it))
|
||||
} ?: kotlin.run {
|
||||
} ?: run {
|
||||
view.findViewById<TextView>(R.id.item_emoji_tv).isVisible = true
|
||||
view.findViewById<ImageView>(R.id.item_emoji_image).isVisible = false
|
||||
view.findViewById<TextView>(R.id.item_emoji_tv).text = rep.emoji
|
||||
|
|
Loading…
Reference in New Issue