This commit is contained in:
Thibault Deckers 2024-09-30 23:54:18 +02:00
parent c982811748
commit 34ff91ccea

View file

@ -75,7 +75,7 @@ class AppProfileHandler(private val activity: Activity) : MethodCallHandler {
val crossProfileApps = activity.getSystemService(Context.CROSS_PROFILE_APPS_SERVICE) as CrossProfileApps
val userHandles = crossProfileApps.targetUserProfiles
val label = crossProfileApps.getProfileSwitchingLabel(userHandles.first())
val label = if (userHandles.isEmpty()) "" else crossProfileApps.getProfileSwitchingLabel(userHandles.first())
result.success(label)
}