summaryrefslogtreecommitdiff
path: root/app/src/main
diff options
context:
space:
mode:
authorGuillaume Jacquart <guillaume.jacquart-ext@mousquetaires.com>2022-07-28 09:33:02 +0200
committerGuillaume Jacquart <guillaume.jacquart-ext@mousquetaires.com>2022-08-18 09:46:05 +0200
commit5abef149e43f51ad3afe2ae248a090ad547f8b17 (patch)
treeb98650bd057adcec3ab428014ef1f3fddacb3e86 /app/src/main
parent8884e0423a4e50406b221ee07321a8560bb7420c (diff)
5444 fix app trackers screen doesn't open for system dummy app.
Diffstat (limited to 'app/src/main')
-rw-r--r--app/src/main/java/foundation/e/privacycentralapp/features/trackers/apptrackers/AppTrackersFragment.kt9
1 files changed, 3 insertions, 6 deletions
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
}
}