From 47096be3ad466134b8cb06489b9f0e7a7bc17f82 Mon Sep 17 00:00:00 2001 From: dcode Date: Sat, 23 Oct 2021 16:42:38 +0200 Subject: [PATCH] fix: Update GitHub authorization (#1) --- index.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 70b3f3a..731f1ae 100644 --- a/index.js +++ b/index.js @@ -224,12 +224,13 @@ export function publishRelease(nextVersion, commit, notes) { const req = request({ hostname: 'api.github.com', port: 443, - path: `/repos/${repo}/releases?access_token=${token}`, + path: `/repos/${repo}/releases`, method: "POST", headers: { "Content-Type": "application/json; charset=utf-8", "Content-Length": data.length, - "User-Agent": "aspublish" + "User-Agent": "aspublish", + "Authorization": `token ${token}` } }, res => { const chunks = [];