Fix network callback for restarted service

This commit is contained in:
sim 2022-05-10 08:22:01 +02:00
parent 667c6e989f
commit 530e55f5f2
1 changed files with 1 additions and 0 deletions

View File

@ -89,6 +89,7 @@ class StartService: Service(){
nFails = 0
apiDestroy()
connectivityManager?.unregisterNetworkCallback(networkCallback)
isCallbackRegistered = false
wakeLock?.let {
while (it.isHeld) {
it.release()