From f321e9b95abb161c9791bf0fb9674fe59edf7033 Mon Sep 17 00:00:00 2001 From: Sina Date: Tue, 9 Feb 2021 16:30:51 +0000 Subject: [PATCH] fix: set Authorization header on search request (#282) --- index.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/index.js b/index.js index 4031a392..0e61b2de 100644 --- a/index.js +++ b/index.js @@ -133,6 +133,9 @@ async function main() { if (remoteBranchExists) { const q = `head:${inputs.branch} type:pr is:open repo:${process.env.GITHUB_REPOSITORY}`; const { data } = await request("GET /search/issues", { + headers: { + authorization: `token ${process.env.GITHUB_TOKEN}`, + }, q, });