fix: [code-970]: add commitsha to merge api (#766)

pull/3408/head^2
Calvin Lee 2023-11-03 17:40:11 +00:00 committed by Harness
parent db7655c569
commit afb21a3ca3
1 changed files with 4 additions and 1 deletions

View File

@ -314,7 +314,10 @@ export const PullRequestActionsBox: React.FC<PullRequestActionsBoxProps> = ({
{...permissionProps(permPushResult, standalone)}
onClick={async () => {
if (mergeOption.method !== 'close') {
const payload: OpenapiMergePullReq = { method: mergeOption.method }
const payload: OpenapiMergePullReq = {
method: mergeOption.method,
source_sha: pullRequestMetadata?.source_sha
}
mergePR(payload)
.then(onPRStateChanged)
.catch(exception => showError(getErrorMessage(exception)))