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

Unified Diff: sync/internal_api/attachments/fake_attachment_uploader.cc

Issue 278263003: Add a minimal AttachmentUploaderImpl. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Apply 2nd round of CR feedback from pavely. Created 6 years, 7 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
Index: sync/internal_api/attachments/fake_attachment_uploader.cc
diff --git a/sync/internal_api/attachments/fake_attachment_uploader.cc b/sync/internal_api/attachments/fake_attachment_uploader.cc
index e73ea6b07e3411a6b4c5bdca1a1effffab151fa3..743b534e839a3695137f308fb7433e8d23108a6f 100644
--- a/sync/internal_api/attachments/fake_attachment_uploader.cc
+++ b/sync/internal_api/attachments/fake_attachment_uploader.cc
@@ -7,6 +7,7 @@
#include "base/bind.h"
#include "base/message_loop/message_loop.h"
#include "sync/api/attachments/attachment.h"
+#include "sync/protocol/sync.pb.h"
namespace syncer {
@@ -21,6 +22,8 @@ FakeAttachmentUploader::~FakeAttachmentUploader() {
void FakeAttachmentUploader::UploadAttachment(const Attachment& attachment,
const UploadCallback& callback) {
DCHECK(CalledOnValidThread());
+ DCHECK(!attachment.GetId().GetProto().unique_id().empty());
+
UploadResult result = UPLOAD_SUCCESS;
AttachmentId updated_id = attachment.GetId();
// TODO(maniscalco): Update the attachment id with server address information

Powered by Google App Engine
This is Rietveld 408576698