From f676edb856fbcf0406965bf14692e13ba2e55b0e Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 13 Apr 2018 23:32:54 +0300 Subject: fixes #1176 (Autobackup to CloudFile doesn't work) --- plugins/CloudFile/src/Services/google_service.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'plugins') diff --git a/plugins/CloudFile/src/Services/google_service.cpp b/plugins/CloudFile/src/Services/google_service.cpp index fe5baa91e3..c7c24333ac 100644 --- a/plugins/CloudFile/src/Services/google_service.cpp +++ b/plugins/CloudFile/src/Services/google_service.cpp @@ -187,11 +187,11 @@ auto CGDriveService::UploadFileChunk(const std::string &uploadUri, const char *c GDriveAPI::UploadFileChunkRequest request(uploadUri.c_str(), chunk, chunkSize, offset, fileSize); NLHR_PTR response(request.Send(m_hConnection)); - HandleHttpError(response); - if (response->resultCode == HTTP_CODE_PERMANENT_REDIRECT) return std::string(); + HandleHttpError(response); + if (HTTP_CODE_SUCCESS(response->resultCode)) { JSONNode root = GetJsonResponse(response); return root["id"].as_string(); -- cgit v1.2.3