Skip to content

Commit

Permalink
Always clean up ThreeDS2Service before starting 3DS transaction
Browse files Browse the repository at this point in the history
This solves an issue in the frictionless flow where if the first
challenge fails and the second is retried with a different card, it
would fail as well. Because the second challenge would be performed
with data from the first challenge.

COAND-771
  • Loading branch information
OscarSpruit committed Jun 21, 2023
1 parent 399f7cb commit 697ed6f
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,8 @@ class Adyen3DS2Component(
notifyException(CheckoutException("Unexpected 3DS2 exception.", throwable))
}
viewModelScope.launch(Dispatchers.Default + coroutineExceptionHandler) {
// This makes sure the 3DS2 SDK doesn't re-use any state from previous transactions
closeTransaction(getApplication())
try {
Logger.d(TAG, "initialize 3DS2 SDK")
ThreeDS2Service.INSTANCE.initialize(activity, configParameters, null, mUiCustomization)
Expand Down

0 comments on commit 697ed6f

Please sign in to comment.