mirror of
https://github.com/TeamVanced/VancedMicroG
synced 2024-12-29 06:05:47 +01:00
also catch potential stopAdvertising exceptions
This commit is contained in:
parent
88d14e9e8a
commit
10455df7e2
@ -218,7 +218,11 @@ class AdvertiserService : LifecycleService() {
|
||||
Log.i(TAG, "Tried calling stopAdvertisingSet without android.permission.BLUETOOTH_ADVERTISE permission.", )
|
||||
}
|
||||
} else {
|
||||
advertiser?.stopAdvertising(callback)
|
||||
try {
|
||||
advertiser?.stopAdvertising(callback)
|
||||
} catch (e: SecurityException) {
|
||||
Log.i(TAG, "stopAdvertising() failed with a SecurityException. Maybe some permissions are missing?", )
|
||||
}
|
||||
}
|
||||
handler.postDelayed(startLaterRunnable, 1000)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user