From f7cca0fc0c713beea3a6b83a23d80e56c012e85c Mon Sep 17 00:00:00 2001 From: Benoit Marty Date: Thu, 6 Nov 2025 18:16:39 +0100 Subject: [PATCH] Ensure the form data are not lost when opening the log viewer. Closes #5579 --- .../features/rageshake/impl/bugreport/BugReportPresenter.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/features/rageshake/impl/src/main/kotlin/io/element/android/features/rageshake/impl/bugreport/BugReportPresenter.kt b/features/rageshake/impl/src/main/kotlin/io/element/android/features/rageshake/impl/bugreport/BugReportPresenter.kt index bfcfcf424e..659c397c96 100644 --- a/features/rageshake/impl/src/main/kotlin/io/element/android/features/rageshake/impl/bugreport/BugReportPresenter.kt +++ b/features/rageshake/impl/src/main/kotlin/io/element/android/features/rageshake/impl/bugreport/BugReportPresenter.kt @@ -32,7 +32,7 @@ class BugReportPresenter( private val bugReporter: BugReporter, private val crashDataStore: CrashDataStore, private val screenshotHolder: ScreenshotHolder, - @AppCoroutineScope + @param:AppCoroutineScope private val appCoroutineScope: CoroutineScope, ) : Presenter { private class BugReporterUploadListener( @@ -77,7 +77,7 @@ class BugReportPresenter( val sendingAction: MutableState> = remember { mutableStateOf(AsyncAction.Uninitialized) } - val formState: MutableState = remember { + val formState: MutableState = rememberSaveable { mutableStateOf(BugReportFormState.Default) } val uploadListener = BugReporterUploadListener(sendingProgress, sendingAction)