0
0
Fork 0
mirror of https://github.com/YTVanced/VancedMicroG synced 2024-11-13 06:25:06 +00:00

Handle callback when returning early

This commit is contained in:
Christian Grigis 2020-10-27 10:42:24 +01:00 committed by Marvin W
parent f2bc5f5baa
commit 42da7aa2fa

View file

@ -86,7 +86,10 @@ class ExposureNotificationServiceImpl(private val context: Context, private val
}
override fun start(params: StartParams) {
if (ExposurePreferences(context).enabled) return
if (ExposurePreferences(context).enabled) {
params.callback.onResult(Status.SUCCESS)
return
}
lifecycleScope.launchWhenStarted {
val status = confirmPermission(CONFIRM_ACTION_START)
if (status.isSuccess) {