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

Commit 426b942e authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Fixed SystemServiceRegistry to return a null AppPredictionManager when...

Merge "Fixed SystemServiceRegistry to return a null AppPredictionManager when the service is not defined."
parents 29569b51 6378bd40
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1163,7 +1163,8 @@ public final class SystemServiceRegistry {
            @Override
            public AppPredictionManager createService(ContextImpl ctx)
                    throws ServiceNotFoundException {
                return new AppPredictionManager(ctx);
                IBinder b = ServiceManager.getService(Context.APP_PREDICTION_SERVICE);
                return b == null ? null : new AppPredictionManager(ctx);
            }
        });

+3 −0
Original line number Diff line number Diff line
@@ -4117,6 +4117,9 @@ public abstract class Context {
    /**
     * Official published name of the app prediction service.
     *
     * <p><b>NOTE: </b> this service is optional; callers of
     * {@code Context.getSystemServiceName(APP_PREDICTION_SERVICE)} should check for {@code null}.
     *
     * @hide
     * @see #getSystemService(String)
     */