Fix gosec's G601

This commit is contained in:
Deluan
2020-05-13 15:32:42 -04:00
parent 162971f7b3
commit 5ce3135f00
6 changed files with 22 additions and 11 deletions
+2 -1
View File
@@ -135,7 +135,8 @@ func (b *browser) buildArtistDir(a *model.Artist, albums model.Albums) *Director
}
dir.Entries = make(Entries, len(albums))
for i, al := range albums {
for i := range albums {
al := albums[i]
dir.Entries[i] = FromAlbum(&al)
dir.PlayCount += int32(al.PlayCount)
}