ci: correctly delete the head branch (#388)

This commit is contained in:
Vlad Frangu
2022-03-31 16:17:34 +03:00
committed by GitHub
parent f0ab4e8c48
commit 6900b74865

View File

@@ -85,7 +85,7 @@ if (previousPullRequest) {
await octokit.request('DELETE /repos/{owner}/{repo}/git/refs/{ref}', {
owner: OWNER,
repo: REPOSITORY,
ref: `heads/chore/release/${newVersion['discord-api-types']}`,
ref: `heads/${previousPullRequest.head.ref}`,
});
console.log(`✅ Done. Pull request ${previousPullRequest.number} was closed and will be recreated.`);