1
0

Nah, 3KiB should be enought to read.

This commit is contained in:
Alexander Andreev 2023-03-12 22:06:15 +04:00
parent 341ea73e97
commit 63fcb36e60
Signed by: Arav
GPG Key ID: D22A817D95815393

View File

@ -18,7 +18,7 @@ const (
IcecastPlaylistDateFormat = "02/Jan/2006:15:04:05 -0700"
SongTimeFormat = "2006 15:04-0700"
bufferSize = 16384
bufferSize = 3072
)
var (
@ -133,7 +133,7 @@ func icecastLastPlayedSongs(playlistPath string, n int) ([]Song, error) {
return nil, nil
}
lines = lines[:len(lines)-1]
lines = lines[:len(lines)]
if len(lines) > n {
lines = lines[len(lines)-n:]