mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-09-26 02:26:41 +02:00
Improves external signer logs
This commit is contained in:
@@ -74,7 +74,7 @@ fun ExternalSignerButton(loginViewModel: LoginViewModel) {
|
||||
launcher.launch(ExternalSignerLogin.createIntent(DefaultSignerPermissions))
|
||||
} catch (e: Exception) {
|
||||
if (e is CancellationException) throw e
|
||||
Log.e("Signer", "Error opening Signer app", e)
|
||||
Log.e("ExternalSigner", "Error opening Signer app", e)
|
||||
loginViewModel.errorManager.error(R.string.error_opening_external_signer)
|
||||
}
|
||||
}
|
||||
|
@@ -22,6 +22,8 @@ package com.vitorpamplona.quartz.nip55AndroidSigner.api.foreground
|
||||
|
||||
import android.content.ActivityNotFoundException
|
||||
import android.content.Intent
|
||||
import android.util.Log
|
||||
import android.util.Log.e
|
||||
import androidx.collection.LruCache
|
||||
import com.vitorpamplona.quartz.nip55AndroidSigner.api.IResult
|
||||
import com.vitorpamplona.quartz.nip55AndroidSigner.api.SignerResult
|
||||
@@ -119,10 +121,12 @@ class IntentRequestManager(
|
||||
|
||||
try {
|
||||
launcher.invoke(requestIntent)
|
||||
} catch (_: ActivityNotFoundException) {
|
||||
} catch (e: ActivityNotFoundException) {
|
||||
Log.e("ExternalSigner", "Error launching intent", e)
|
||||
awaitingRequests.remove(callId)
|
||||
continuation.resume(activityNotFoundIntent)
|
||||
} catch (e: Exception) {
|
||||
Log.e("ExternalSigner", "Error launching intent", e)
|
||||
awaitingRequests.remove(callId)
|
||||
continuation.resume(null)
|
||||
if (e is CancellationException) throw e
|
||||
|
Reference in New Issue
Block a user