fix: 初始化 BeatLeader 和 ScoreSaber 歌曲哈希映射,防止空指针异常
This commit is contained in:
parent
8b4866b4d3
commit
d68f9c0e89
@ -369,6 +369,7 @@ func (bl *blQuery) GetRecentScores(count int, qqId string) ([]RecordDataLite, er
|
||||
|
||||
func GetSongIdsByHash(hashs []string) (hashToSongId map[string]string, err error) {
|
||||
//每批最多49个
|
||||
hashToSongId = make(map[string]string)
|
||||
batchSize := 49
|
||||
for i := 0; i < len(hashs); i += batchSize {
|
||||
end := i + batchSize
|
||||
|
@ -397,6 +397,7 @@ func (ss *ssQuery) GetRecentScores(count int, qqId string) ([]RecordDataLite, er
|
||||
|
||||
func GetSongIdsByHash(hashs []string) (hashToSongId map[string]string, err error) {
|
||||
//每批最多49个
|
||||
hashToSongId = make(map[string]string)
|
||||
batchSize := 49
|
||||
for i := 0; i < len(hashs); i += batchSize {
|
||||
end := i + batchSize
|
||||
|
Loading…
x
Reference in New Issue
Block a user