Browse Source

fix #1189, commit messages containing a pipe (#1203)

Philippe Kueck 2 years ago
parent
commit
e2b2fd6e78
1 changed files with 2 additions and 2 deletions
  1. 2 2
      models/graph.go

+ 2 - 2
models/graph.go

@@ -78,8 +78,8 @@ func graphItemFromString(s string, r *git.Repository) (GraphItem, error) {
78 78
 		return GraphItem{}, fmt.Errorf("Failed parsing grap line:%s. Expect 1 or two fields", s)
79 79
 	}
80 80
 
81
-	rows := strings.Split(data, "|")
82
-	if len(rows) != 8 {
81
+	rows := strings.SplitN(data, "|", 8)
82
+	if len(rows) < 8 {
83 83
 		return GraphItem{}, fmt.Errorf("Failed parsing grap line:%s - Should containt 8 datafields", s)
84 84
 	}
85 85