Remove delegations before transfering device owner permission

This commit is contained in:
Jonas Lochmann 2023-06-19 02:00:00 +02:00
parent 5760f548f6
commit 21d3db791d
No known key found for this signature in database
GPG key ID: 8B8C9AEE10FA5B36

View file

@ -121,6 +121,7 @@ class AndroidDeviceOwnerApi(
if (dryRun) return if (dryRun) return
devicePolicyManager.setDelegatedScopes(componentName, packageName, emptyList())
devicePolicyManager.transferOwnership(componentName, targetComponentName, null) devicePolicyManager.transferOwnership(componentName, targetComponentName, null)
} }
} }