kopia lustrzana https://github.com/meshtastic/Meshtastic-Android
fix: avoid starting FGS with location type without permission
rodzic
c536679762
commit
ac928b40d4
|
@ -291,7 +291,11 @@ class MeshService : Service(), Logging {
|
|||
serviceNotifications.notifyId,
|
||||
notification,
|
||||
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.Q) {
|
||||
ServiceInfo.FOREGROUND_SERVICE_TYPE_MANIFEST
|
||||
if (hasLocationPermission()) {
|
||||
ServiceInfo.FOREGROUND_SERVICE_TYPE_MANIFEST
|
||||
} else {
|
||||
ServiceInfo.FOREGROUND_SERVICE_TYPE_CONNECTED_DEVICE
|
||||
}
|
||||
} else {
|
||||
0
|
||||
},
|
||||
|
|
Ładowanie…
Reference in New Issue