implementing PR bot feedback

This commit is contained in:
mhoecke1
2024-08-23 11:18:42 -04:00
parent 2a9e3ee1ef
commit a99ebf8953
2 changed files with 12 additions and 17 deletions

View File

@ -139,8 +139,7 @@ class BitbucketServerProvider(GitProvider):
#gets the best common ancestor: https://git-scm.com/docs/git-merge-base
@staticmethod
def get_best_common_ancestor(source_commits_list, destination_commits_list, guaranteed_common_ancestor) -> str:
destination_commit_hashes = {commit['id'] for commit in destination_commits_list}
destination_commit_hashes.add(guaranteed_common_ancestor)
destination_commit_hashes = {commit['id'] for commit in destination_commits_list} | {guaranteed_common_ancestor}
for commit in source_commits_list:
for parent_commit in commit['parents']: