1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2024-11-28 09:08:41 +02:00

Discard value after END marker

This commit is contained in:
Cristian Betivu 2021-06-02 19:53:01 +02:00 committed by Jesse Duffield
parent fd38ad8096
commit 05a23f0e1e

View File

@ -35,6 +35,8 @@ func findConflicts(content string) []*mergeConflict {
case END: case END:
newConflict.end = i newConflict.end = i
conflicts = append(conflicts, newConflict) conflicts = append(conflicts, newConflict)
// reset value to avoid any possible silent mutations in further iterations
newConflict = nil
default: default:
// line isn't a merge conflict marker so we just continue // line isn't a merge conflict marker so we just continue
} }