Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1242)

Unified Diff: sync/android/java/src/org/chromium/sync/notifier/InvalidationPreferences.java

Issue 573733004: Roll cacheinvalidation DEPS to r341 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@fix-navigation-controller
Patch Set: Rebased Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « DEPS ('k') | third_party/cacheinvalidation/README.chromium » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sync/android/java/src/org/chromium/sync/notifier/InvalidationPreferences.java
diff --git a/sync/android/java/src/org/chromium/sync/notifier/InvalidationPreferences.java b/sync/android/java/src/org/chromium/sync/notifier/InvalidationPreferences.java
index c3192ef210003ba062fb0ba8384a93f1b6a5af09..0a128492ebf32a27d68ff03e37b0036dc0e6f211 100644
--- a/sync/android/java/src/org/chromium/sync/notifier/InvalidationPreferences.java
+++ b/sync/android/java/src/org/chromium/sync/notifier/InvalidationPreferences.java
@@ -11,7 +11,6 @@ import android.preference.PreferenceManager;
import android.util.Base64;
import android.util.Log;
-import com.google.common.base.Preconditions;
import com.google.ipc.invalidation.external.client.types.ObjectId;
import org.chromium.base.VisibleForTesting;
@@ -112,7 +111,7 @@ public class InvalidationPreferences {
/** Sets the saved sync types to {@code syncTypes} in {@code editContext}. */
public void setSyncTypes(EditContext editContext, Collection<String> syncTypes) {
- Preconditions.checkNotNull(syncTypes);
+ if (syncTypes == null) throw new NullPointerException("syncTypes is null.");
Colin Meek 2014/09/16 17:54:35 Do you typically use braces around 'if' block?
nyquist 2014/09/16 17:59:04 Yes, but one-liners are OK if they make sense. We
Set<String> selectedTypesSet = new HashSet<String>(syncTypes);
editContext.mEditor.putStringSet(PrefKeys.SYNC_TANGO_TYPES, selectedTypesSet);
}
@@ -137,7 +136,7 @@ public class InvalidationPreferences {
/** Sets the saved non-sync object ids */
public void setObjectIds(EditContext editContext, Collection<ObjectId> objectIds) {
- Preconditions.checkNotNull(objectIds);
+ if (objectIds == null) throw new NullPointerException("objectIds is null.");
Set<String> objectIdStrings = new HashSet<String>(objectIds.size());
for (ObjectId objectId : objectIds) {
objectIdStrings.add(getObjectIdString(objectId));
« no previous file with comments | « DEPS ('k') | third_party/cacheinvalidation/README.chromium » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698