From debeaa181cffd6f458a157f8358d0ab07de77b14 Mon Sep 17 00:00:00 2001 From: Veikko Sariola Date: Mon, 26 Oct 2020 12:48:33 +0200 Subject: [PATCH] Fix bug in song.go: len(s.Patterns) should have been len(s.Tracks). --- song/song.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/song/song.go b/song/song.go index eeb76e6..a44d335 100644 --- a/song/song.go +++ b/song/song.go @@ -42,7 +42,7 @@ func (s *Song) Validate() error { return errors.New("Every pattern should have the same length") } } - for i := range s.Tracks[:len(s.Patterns)-1] { + for i := range s.Tracks[:len(s.Tracks)-1] { if len(s.Tracks[i].Sequence) != len(s.Tracks[i+1].Sequence) { return errors.New("Every track should have the same sequence length") }