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

Commit d8abd6a1 authored by Matthew Williams's avatar Matthew Williams
Browse files

Preserve CTS fail behaviour on null bundle for old API

For ContentResolver.requestSync() a null bundle should not be
allowed. However we don't want to enforce this for the new API,
so we remove this check from the SyncRequest.Builder#build()

Change-Id: I69353d24edbd686da6ded2856c0920315cb76e85
parent 30590646
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -1745,6 +1745,9 @@ public abstract class ContentResolver {
     * @param extras any extras to pass to the SyncAdapter.
     */
    public static void requestSync(Account account, String authority, Bundle extras) {
        if (extras == null) {
            throw new IllegalArgumentException("Must specify extras.");
        }
        SyncRequest request =
            new SyncRequest.Builder()
                .setSyncAdapter(account, authority)