(baseRepo ghrepo.Interface, pr *api.PullRequest, opts *MergeOptions)
| 742 | } |
| 743 | |
| 744 | func remoteForMergeConflictResolution(baseRepo ghrepo.Interface, pr *api.PullRequest, opts *MergeOptions) *ghContext.Remote { |
| 745 | if !mergeConflictStatus(pr.MergeStateStatus) || !opts.CanDeleteLocalBranch { |
| 746 | return nil |
| 747 | } |
| 748 | remotes, err := opts.Remotes() |
| 749 | if err != nil { |
| 750 | return nil |
| 751 | } |
| 752 | remote, err := remotes.FindByRepo(baseRepo.RepoOwner(), baseRepo.RepoName()) |
| 753 | if err != nil { |
| 754 | return nil |
| 755 | } |
| 756 | return remote |
| 757 | } |
| 758 | |
| 759 | func mergeConflictStatus(status string) bool { |
| 760 | return status == MergeStateStatusDirty |
no test coverage detected