Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/bitbucket/representation/pull_request.rb')
-rw-r--r--lib/bitbucket/representation/pull_request.rb13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/bitbucket/representation/pull_request.rb b/lib/bitbucket/representation/pull_request.rb
index ab8f5ba17fe..3505e34e0ba 100644
--- a/lib/bitbucket/representation/pull_request.rb
+++ b/lib/bitbucket/representation/pull_request.rb
@@ -76,6 +76,7 @@ module Bitbucket
merge_commit_sha: merge_commit_sha,
target_branch_name: target_branch_name,
target_branch_sha: target_branch_sha,
+ source_and_target_project_different: source_and_target_project_different,
reviewers: reviewers
}
end
@@ -89,6 +90,18 @@ module Bitbucket
def target_branch
raw['destination']
end
+
+ def source_repo_uuid
+ source_branch&.dig('repository', 'uuid')
+ end
+
+ def target_repo_uuid
+ target_branch&.dig('repository', 'uuid')
+ end
+
+ def source_and_target_project_different
+ source_repo_uuid != target_repo_uuid
+ end
end
end
end