From b03a202ace130a2bb3703b524e9baac1848cb141 Mon Sep 17 00:00:00 2001 From: Steve Peak Date: Thu, 30 Nov 2017 17:27:05 +0100 Subject: [PATCH] update to use upload/v4 endpoint The `Content-Type` of `plain/text` was a mistake in v3. Fixed in v4. --- lib/codecov.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/codecov.js b/lib/codecov.js index 99dd8f09..a15e681c 100644 --- a/lib/codecov.js +++ b/lib/codecov.js @@ -167,7 +167,7 @@ var sendToCodecovV3 = function(codecov_endpoint, query, upload_body, on_success, // Direct to S3 request.post( { - url : urlgrey(codecov_endpoint + '/upload/v3').query(query).toString(), + url : urlgrey(codecov_endpoint + '/upload/v4').query(query).toString(), body : '', headers : { 'Content-Type': 'text/plain', @@ -184,7 +184,7 @@ var sendToCodecovV3 = function(codecov_endpoint, query, upload_body, on_success, url : result.split('\n')[1], body : upload_body, headers : { - 'Content-Type': 'plain/text', + 'Content-Type': 'text/plain', 'x-amz-acl': 'public-read' } }, function(err, response, result){