File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
kaspresso/src/main/kotlin/com/kaspersky/kaspresso/failure Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ class FailureLoggingProviderImpl(
7777 * @return transformed [error].
7878 */
7979 private fun Throwable.describedWith (viewMatcher : Matcher <View >? ): Throwable {
80- return when {
80+ val newError = when {
8181 this is PerformException -> {
8282 PerformException .Builder ()
8383 .from(this )
@@ -93,7 +93,11 @@ class FailureLoggingProviderImpl(
9393 RuntimeException (message.toString())
9494 }
9595 else -> this
96- }.apply { stackTrace = Thread .currentThread().stackTrace }
96+ }
97+ newError.stackTrace = Thread .currentThread().stackTrace
98+ newError.addSuppressed(this )
99+
100+ return newError
97101 }
98102
99103 private fun isWebViewException (throwable : Throwable ): Boolean {
You can’t perform that action at this time.
0 commit comments