change to uninitialize slice instead of initialized

This commit is contained in:
raziman 2020-08-25 21:11:39 +08:00
parent cd2312badf
commit c65784aa50

View File

@ -221,9 +221,9 @@ func (c Command) defineCommands() {
return
}
audios := make([]string, len(queue.items))
for i, file := range queue.items {
audios[i] = file.name
audios := make([]string, 0, len(queue.items))
for _, file := range queue.items {
audios = append(audios, file.name)
}
searchPopup(audios, func(selected string) {