From 0d5996fe8616e1117c4a622aa19d7c510be24fa8 Mon Sep 17 00:00:00 2001 From: Marinov Date: Wed, 4 Mar 2026 19:04:14 +0200 Subject: [PATCH] [MS-1377] Remove graph init state persistence that was never called --- .../feature/orchestrator/OrchestratorActivity.kt | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/feature/orchestrator/src/main/java/com/simprints/feature/orchestrator/OrchestratorActivity.kt b/feature/orchestrator/src/main/java/com/simprints/feature/orchestrator/OrchestratorActivity.kt index c83cad484e..2e11ba9800 100644 --- a/feature/orchestrator/src/main/java/com/simprints/feature/orchestrator/OrchestratorActivity.kt +++ b/feature/orchestrator/src/main/java/com/simprints/feature/orchestrator/OrchestratorActivity.kt @@ -2,7 +2,6 @@ package com.simprints.feature.orchestrator import android.content.Intent import android.os.Bundle -import android.os.PersistableBundle import androidx.core.os.bundleOf import androidx.navigation.findNavController import com.simprints.core.tools.activity.BaseActivity @@ -29,7 +28,7 @@ internal class OrchestratorActivity : BaseActivity() { /** * Flag for the navigation graph initialization state. The graph should only be initialized once - * during the existence of this activity, and the flag tracks graph's state. + * while the activity is in memory. Recreation of the activity should result in graph re-init */ private var isGraphInitialized = false @@ -37,7 +36,6 @@ internal class OrchestratorActivity : BaseActivity() { super.onCreate(savedInstanceState) Simber.d("OrchestratorActivity.onCreate isGraphInitialized=$isGraphInitialized", tag = ORCHESTRATION) - isGraphInitialized = savedInstanceState?.getBoolean(KEY_IS_GRAPH_INITIALIZED) ?: false lifecycle.addObserver(activityTracker) setContentView(binding.root) @@ -80,16 +78,4 @@ internal class OrchestratorActivity : BaseActivity() { finish() } } - - override fun onSaveInstanceState( - outState: Bundle, - outPersistentState: PersistableBundle, - ) { - outState.putBoolean(KEY_IS_GRAPH_INITIALIZED, isGraphInitialized) - super.onSaveInstanceState(outState, outPersistentState) - } - - companion object { - private const val KEY_IS_GRAPH_INITIALIZED = "KEY_IS_GRAPH_INITIALIZED" - } }