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

Commit 599fd5a8 authored by Jeff Sharkey's avatar Jeff Sharkey Committed by android-build-merger
Browse files

Merge \\"Handle auto-unlocked managed profiles.\\" into nyc-mr1-dev am: 2b58e464

am: 502087e4

Change-Id: I16b8beb110c534124475e7e0111a912ffa3e5799
parents ec8180f9 502087e4
Loading
Loading
Loading
Loading
+9 −3
Original line number Diff line number Diff line
@@ -352,9 +352,15 @@ final class UserController {
                final UserInfo info = getUserInfo(userId);
                if (!Objects.equals(info.lastLoggedInFingerprint, Build.FINGERPRINT)) {
                    // Suppress double notifications for managed profiles that
                    // were unlocked automatically (no challenge token required)
                    // as part of their parent user being unlocked.
                    final boolean quiet = info.isManagedProfile() && !uss.tokenProvided;
                    // were unlocked automatically as part of their parent user
                    // being unlocked.
                    final boolean quiet;
                    if (info.isManagedProfile()) {
                        quiet = !uss.tokenProvided
                                || !mLockPatternUtils.isSeparateProfileChallengeEnabled(userId);
                    } else {
                        quiet = false;
                    }
                    new PreBootBroadcaster(mService, userId, null, quiet) {
                        @Override
                        public void onFinished() {