Skip to content

Commit

Permalink
fix(payload_api, git_diff): Accessing correct property in payload and…
Browse files Browse the repository at this point in the history
… Replacing --quiet with --no-patch in git diff (#1934)
  • Loading branch information
codesculpture committed Feb 17, 2024
1 parent 68bd453 commit e3cac49
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/commitSha.ts
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,7 @@ export const getSHAForPullRequestEvent = async (

if (
!github.context.payload.pull_request?.base?.ref ||
github.context.payload.head?.repo?.fork === 'true'
github.context.payload.pull_request?.head?.repo?.fork === true
) {
diff = '..'
}
Expand Down
2 changes: 1 addition & 1 deletion src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -908,7 +908,7 @@ export const canDiffCommits = async ({
} else {
const {exitCode, stderr} = await exec.getExecOutput(
'git',
['diff', '--quiet', sha1, sha2],
['diff', '--no-patch', sha1, sha2],
{
cwd,
ignoreReturnCode: true,
Expand Down

0 comments on commit e3cac49

Please sign in to comment.