From 2b5e4b4d96702107d2624fd923d1ec551843e4b9 Mon Sep 17 00:00:00 2001 From: Philippe Kueck Date: Thu, 16 Mar 2017 12:41:19 +0100 Subject: [PATCH] fix #1189, commit messages containing a pipe (#1218) (d680164f11dbec9ad593c55030387b0bbf1a116d) --- models/graph.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/models/graph.go b/models/graph.go index 7413f409d..cfd583ca8 100644 --- a/models/graph.go +++ b/models/graph.go @@ -78,8 +78,8 @@ func graphItemFromString(s string, r *git.Repository) (GraphItem, error) { return GraphItem{}, fmt.Errorf("Failed parsing grap line:%s. Expect 1 or two fields", s) } - rows := strings.Split(data, "|") - if len(rows) != 8 { + rows := strings.SplitN(data, "|", 8) + if len(rows) < 8 { return GraphItem{}, fmt.Errorf("Failed parsing grap line:%s - Should containt 8 datafields", s) }