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

Commit 3506a5b8 authored by Tyler Gunn's avatar Tyler Gunn Committed by Gerrit Code Review
Browse files

Merge "Add compatibility method for isBlocked."

parents 12456b58 dd222c3a
Loading
Loading
Loading
Loading
+17 −0
Original line number Diff line number Diff line
@@ -12,6 +12,23 @@ public class BlockChecker {
    private static final String TAG = "BlockChecker";
    private static final boolean VDBG = false; // STOPSHIP if true.

    /**
     * Returns {@code true} if {@code phoneNumber} is blocked according to {@code extras}.
     * <p>
     * This method catches all underlying exceptions to ensure that this method never throws any
     * exception.
     * <p>
     * @deprecated use {@link #isBlocked(Context, String, Bundle)} instead.
     *
     * @param context the context of the caller.
     * @param phoneNumber the number to check.
     * @return {@code true} if the number is blocked. {@code false} otherwise.
     */
    @Deprecated
    public static boolean isBlocked(Context context, String phoneNumber) {
        return isBlocked(context, phoneNumber, null /* extras */);
    }

    /**
     * Returns {@code true} if {@code phoneNumber} is blocked according to {@code extras}.
     * <p>