Bug 1153358 - Client mitigation: don't upload stored_on. r=nalexander, a=sledru
authorRichard Newman <rnewman@mozilla.com>
Mon, 13 Apr 2015 12:46:25 -0700
changeset 263179 e71fcee4fabbdcd23ca0861886a81cd9d66e863a
parent 263178 f549efda6b17c7db041ead477ebefdebbe4bb764
child 263180 1566bebe56be3cc71bfe84e1315ae0984fd24a03
push id1963
push userpaolo.mozmail@amadzone.org
push dateSun, 10 May 2015 10:26:20 +0000
reviewersnalexander, sledru
bugs1153358
milestone39.0a2
Bug 1153358 - Client mitigation: don't upload stored_on. r=nalexander, a=sledru
mobile/android/base/reading/ReadingListClientRecordFactory.java
--- a/mobile/android/base/reading/ReadingListClientRecordFactory.java
+++ b/mobile/android/base/reading/ReadingListClientRecordFactory.java
@@ -193,16 +193,20 @@ public class ReadingListClientRecordFact
     final ClientMetadata cm = new ClientMetadata(localID, clientLastModified, isDeleted, isArchived);
 
     // Remove things that aren't part of the spec.
     object.remove("last_modified");
     object.remove("guid");
     object.remove("client_last_modified");
     object.remove("is_deleted");
 
+    // We never want to upload stored_on; for new items it'll be null (and cause Bug 1153358),
+    // and for existing items it should never change.
+    object.remove("stored_on");
+
     object.remove(ReadingListItems.CONTENT_STATUS);
     object.remove(ReadingListItems.SYNC_STATUS);
     object.remove(ReadingListItems.SYNC_CHANGE_FLAGS);
     object.remove(ReadingListItems.CLIENT_LAST_MODIFIED);
 
     return new ClientReadingListRecord(sm, cm, object);
   }