Skip to content

Commit

Permalink
Update working_dir.go (#4048) (#4050)
Browse files Browse the repository at this point in the history
fix mergeAgain function for when the PR is created from a fork

Co-authored-by: Alan Bover <alanbover@gmail.com>
  • Loading branch information
gcp-cherry-pick-bot[bot] and alanbover authored Dec 20, 2023
1 parent e118527 commit b4d8c3e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/events/working_dir.go
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ func (w *FileWorkspace) mergeAgain(c wrappedGitContext) error {
}

// Reset branch as if it was cloned again
if err := w.wrappedGit(c, "reset", "--hard", fmt.Sprintf("refs/remotes/head/%s", c.pr.BaseBranch)); err != nil {
if err := w.wrappedGit(c, "reset", "--hard", fmt.Sprintf("refs/remotes/origin/%s", c.pr.BaseBranch)); err != nil {
return err
}

Expand Down

0 comments on commit b4d8c3e

Please sign in to comment.