From 1f4d311e360ab89826ea4141681e8d75fdeba88b Mon Sep 17 00:00:00 2001 From: Patrick DeVivo Date: Sun, 8 Dec 2019 10:39:53 -0500 Subject: [PATCH] copy blame to new var and use that pointer to fix bug --- pkg/todos/todos.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/todos/todos.go b/pkg/todos/todos.go index 7d0ba9c..f5aff38 100644 --- a/pkg/todos/todos.go +++ b/pkg/todos/todos.go @@ -142,7 +142,8 @@ func (t *ToDos) FindBlame(ctx context.Context, dir string) error { for line, blame := range blames { for _, todo := range todos { if todo.StartLocation.Line == line { - todo.Blame = &blame + b := blame + todo.Blame = &b } } }