Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b2f96a28 authored by Helen Qin's avatar Helen Qin
Browse files

Do not crash ui app upon bad provider pending intent.

Test: manual
Bug: 281335878
Change-Id: I37eb8ecf9d24131cfedc4a5344a5f7c608f44534
parent 76694b6e
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -119,7 +119,12 @@ class CredentialSelectorViewModel(
            uiState = uiState.copy(providerActivityState = ProviderActivityState.PENDING)
            val intentSenderRequest = IntentSenderRequest.Builder(entry.pendingIntent)
                .setFillInIntent(entry.fillInIntent).build()
            try {
                launcher.launch(intentSenderRequest)
            } catch (e: Exception) {
                Log.w(Constants.LOG_TAG, "Failed to launch provider UI: $e")
                onInternalError()
            }
        } else {
            Log.d(Constants.LOG_TAG, "No provider UI to launch")
            onInternalError()