don't leak a reference to the service

This commit is contained in:
geeksville
2020-03-06 20:47:45 -08:00
parent 94dbb237e8
commit f7f201adbc

View File

@@ -241,6 +241,8 @@ class MainActivity : AppCompatActivity(), Logging,
override fun onDestroy() {
unregisterMeshReceiver()
UIState.meshService =
null // When our activity goes away make sure we don't keep a ptr around to the service
super.onDestroy()
}