summaryrefslogtreecommitdiffstats
path: root/services/migrations/gitlab.go
diff options
context:
space:
mode:
Diffstat (limited to 'services/migrations/gitlab.go')
-rw-r--r--services/migrations/gitlab.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/services/migrations/gitlab.go b/services/migrations/gitlab.go
index f626036254..53540899a6 100644
--- a/services/migrations/gitlab.go
+++ b/services/migrations/gitlab.go
@@ -566,6 +566,11 @@ func (g *GitlabDownloader) GetPullRequests(page, perPage int) ([]*base.PullReque
closeTime = pr.UpdatedAt
}
+ mergeCommitSHA := pr.MergeCommitSHA
+ if mergeCommitSHA == "" {
+ mergeCommitSHA = pr.SquashCommitSHA
+ }
+
var locked bool
if pr.State == "locked" {
locked = true
@@ -608,7 +613,7 @@ func (g *GitlabDownloader) GetPullRequests(page, perPage int) ([]*base.PullReque
Closed: closeTime,
Labels: labels,
Merged: merged,
- MergeCommitSHA: pr.MergeCommitSHA,
+ MergeCommitSHA: mergeCommitSHA,
MergedTime: mergeTime,
IsLocked: locked,
Reactions: g.awardsToReactions(reactions),