use pull_request.head.label in comparisons to allow for forks
This commit is contained in:
@@ -25,7 +25,7 @@ const octokit = github.getOctokit(GITHUB_TOKEN)
|
||||
const response = await octokit.rest.repos.compareCommitsWithBasehead({
|
||||
owner: context.repo.owner,
|
||||
repo: context.payload.repository.name,
|
||||
basehead: `${context.payload.pull_request.base.ref}...${context.payload.pull_request.head.ref}`,
|
||||
basehead: `${context.payload.pull_request.base.ref}...${context.payload.pull_request.head.label}`,
|
||||
})
|
||||
|
||||
const { files } = response.data
|
||||
|
||||
Reference in New Issue
Block a user