From 16bdd34a8052638c3a28bd70dc76ad651b3b2ea9 Mon Sep 17 00:00:00 2001 From: Benoit Marty Date: Mon, 29 Apr 2024 15:48:58 +0200 Subject: [PATCH] Add log in case of error. --- .../android/libraries/matrix/impl/timeline/RustTimeline.kt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libraries/matrix/impl/src/main/kotlin/io/element/android/libraries/matrix/impl/timeline/RustTimeline.kt b/libraries/matrix/impl/src/main/kotlin/io/element/android/libraries/matrix/impl/timeline/RustTimeline.kt index 39469b552c..198f231ccb 100644 --- a/libraries/matrix/impl/src/main/kotlin/io/element/android/libraries/matrix/impl/timeline/RustTimeline.kt +++ b/libraries/matrix/impl/src/main/kotlin/io/element/android/libraries/matrix/impl/timeline/RustTimeline.kt @@ -299,6 +299,8 @@ class RustTimeline( specialModeEventTimelineItem?.destroy() specialModeEventTimelineItem = null specialModeEventTimelineItem = eventId?.let { inner.getEventTimelineItemByEventId(it.value) } + }.onFailure { + Timber.e(it, "Unable to retrieve event for special mode. Are you using the correct timeline?") } }