diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2021-06-05 16:39:59 +1000 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2021-06-05 22:15:51 +1000 |
commit | fb395bca6eedfc44afb04ad26005a45e7b7dfea9 (patch) | |
tree | 4669caf828ea97afdb9c829820ff53c5731fcca2 /pkg/commands/loading_commits.go | |
parent | f91adf026bfbddc9505d6d84d3fabc80d49c7ca0 (diff) |
support reverting merge commits
Diffstat (limited to 'pkg/commands/loading_commits.go')
-rw-r--r-- | pkg/commands/loading_commits.go | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/pkg/commands/loading_commits.go b/pkg/commands/loading_commits.go index bb25f4c62..bf7e4cf56 100644 --- a/pkg/commands/loading_commits.go +++ b/pkg/commands/loading_commits.go @@ -72,10 +72,6 @@ func (c *CommitListBuilder) extractCommitFromLine(line string) *models.Commit { unitTimestampInt, _ := strconv.Atoi(unixTimestamp) - // Any commit with multiple parents is a merge commit. - // If there's a space then it means there must be more than one parent hash - isMerge := strings.Contains(parentHashes, " ") - return &models.Commit{ Sha: sha, Name: message, @@ -83,7 +79,7 @@ func (c *CommitListBuilder) extractCommitFromLine(line string) *models.Commit { ExtraInfo: extraInfo, UnixTimestamp: int64(unitTimestampInt), Author: author, - IsMerge: isMerge, + Parents: strings.Split(parentHashes, " "), } } |