Do not use hidden APIs in UserHandle/UserManager
1. UserHandle.<init>: replaced with UserHandle.of()
2. UserHandle.getCallingUserId: removed
2. UserManager.get(): replaced with getSystemService(Context.USER_SERVICE)
Bug: 137202333
Test: make
Change-Id: Ibb5fc644b4de8dfbc6d695c9ae4bc64362c9e1fa
Merged-In: I5aeedfb204d0297ecf5a9f6758562fac24de6e9e
diff --git a/src/com/android/phone/PhoneGlobals.java b/src/com/android/phone/PhoneGlobals.java
index c3c3eb8..de71373 100644
--- a/src/com/android/phone/PhoneGlobals.java
+++ b/src/com/android/phone/PhoneGlobals.java
@@ -274,7 +274,8 @@
// not want this running if the device is still in the FBE encrypted state.
// This is the same procedure that is triggered in the SipIncomingCallReceiver
// upon BOOT_COMPLETED.
- UserManager userManager = UserManager.get(sMe);
+ UserManager userManager =
+ (UserManager) sMe.getSystemService(Context.USER_SERVICE);
if (userManager != null && userManager.isUserUnlocked()) {
SipUtil.startSipService();
}