From 1b179f55a610e212890f25874f29044475fdb016 Mon Sep 17 00:00:00 2001 From: Iván Ávalos Date: Thu, 30 Dec 2021 22:05:55 -0600 Subject: - ViewModel LiveData no longer externally mutable. - Observers in fragments now owned by viewLifecycleOwner. - Disabled center animation on MapFragment startup - Search filter now triggered automatically. - Case insensitive filter logic. --- .../java/mx/trackermap/TrackerMap/android/devices/DevicesFragment.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'androidApp/src/main/java/mx/trackermap/TrackerMap/android/devices') diff --git a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/devices/DevicesFragment.kt b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/devices/DevicesFragment.kt index eb8dcbc..3c2d6ce 100644 --- a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/devices/DevicesFragment.kt +++ b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/devices/DevicesFragment.kt @@ -55,7 +55,7 @@ class DevicesFragment : Fragment() { @DelicateCoroutinesApi private fun setupObservers() { - unitsViewModel.units.observe(this) { units -> + unitsViewModel.units.observe(viewLifecycleOwner) { units -> Log.d("DevicesFragment", "Success $units") binding.devicesList.swapAdapter( DevicesAdapter(units, this::itemAction), -- cgit v1.2.3