commit 1f54a6295f160c0288b713e6b25656484073c438
parent 3729d501d011dc27ee18841f3d0dd7aae7f5dab2
Author: rhunk <101876869+rhunk@users.noreply.github.com>
Date:   Tue, 16 Apr 2024 21:55:15 +0200

refactor(core/media_downloader): status toast

Diffstat:
Mcore/src/main/kotlin/me/rhunk/snapenhance/core/features/impl/downloader/MediaDownloader.kt | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/core/src/main/kotlin/me/rhunk/snapenhance/core/features/impl/downloader/MediaDownloader.kt b/core/src/main/kotlin/me/rhunk/snapenhance/core/features/impl/downloader/MediaDownloader.kt @@ -145,10 +145,10 @@ class MediaDownloader : MessagingRuleFeature("MediaDownloader", MessagingRuleTyp if (context.isMainActivityPaused) { context.shortToast(message) } - throwable?.let { + throwable?.let { t -> context.inAppOverlay.showStatusToast( icon = Icons.Outlined.Error, - text = message + it.takeIf { it.isNotEmpty() }.orEmpty(), + text = message + t.takeIf { it.isNotEmpty() }?.let { " $it" }.orEmpty(), ) return }