From 5abef149e43f51ad3afe2ae248a090ad547f8b17 Mon Sep 17 00:00:00 2001 From: Guillaume Jacquart Date: Thu, 28 Jul 2022 09:33:02 +0200 Subject: 5444 fix app trackers screen doesn't open for system dummy app. --- .../features/trackers/apptrackers/AppTrackersFragment.kt | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'app/src/main/java/foundation/e') diff --git a/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt b/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt index 75a9c4a..67b6093 100644 --- a/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt +++ b/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt @@ -24,7 +24,6 @@ import android.view.View import android.widget.Toast import androidx.core.os.bundleOf import androidx.core.view.isVisible -import androidx.fragment.app.commit import androidx.fragment.app.viewModels import androidx.lifecycle.Lifecycle import androidx.lifecycle.lifecycleScope @@ -69,11 +68,9 @@ class AppTrackersFragment : NavToolbarFragment(R.layout.apptrackers_fragment) { override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) - val appUid = requireArguments().getInt(PARAM_APP_UID, -1) - if (appUid == -1) { - activity?.supportFragmentManager?.commit(allowStateLoss = true) { - remove(this@AppTrackersFragment) - } + if (arguments == null || + requireArguments().getInt(PARAM_APP_UID, Int.MIN_VALUE) == Int.MIN_VALUE) { + activity?.supportFragmentManager?.popBackStack() return } } -- cgit v1.2.1 From 53d11f837acb9a15ae41d257f2afc32c76db3916 Mon Sep 17 00:00:00 2001 From: Guillaume Jacquart Date: Fri, 5 Aug 2022 21:21:21 +0200 Subject: review fixes. --- .../features/trackers/apptrackers/AppTrackersFragment.kt | 1 - 1 file changed, 1 deletion(-) (limited to 'app/src/main/java/foundation/e') diff --git a/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt b/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt index 67b6093..3d8f809 100644 --- a/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt +++ b/app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt @@ -71,7 +71,6 @@ class AppTrackersFragment : NavToolbarFragment(R.layout.apptrackers_fragment) { if (arguments == null || requireArguments().getInt(PARAM_APP_UID, Int.MIN_VALUE) == Int.MIN_VALUE) { activity?.supportFragmentManager?.popBackStack() - return } } -- cgit v1.2.1