Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 02586d4c authored by Eric Biggers's avatar Eric Biggers
Browse files

LockSettingsService: simplify querying of credential shareability

Instead of creating a UserManager for the desired userId and then
calling the deprecated method
UserManager#isCredentialSharableWithParent(), use
UserManagerInternal#getUserProperties(userId).isCredentialShareableWithParent().
UserManagerInternal is the preferred way to get user properties in
system_server itself, since it avoids unnecessary checks and an
unnecessary copy of the UserProperties object.

Also add the missing "e" to
LockSettingsService#isCredentialSharableWithParent().

Bug: 403355811
Test: atest FrameworksServicesTests:com.android.server.locksettings
Flag: EXEMPT refactor
Change-Id: I43d11c3cd87f798a3d782146994e17041e55b268
parent a5bb866c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment