fix songselect when no songs

This commit is contained in:
Bui 2022-03-06 18:24:57 +00:00
parent d47ac381fd
commit 8c8f34f7a3

View File

@ -304,7 +304,7 @@ class SongSelect{
}
this.songSelect = document.getElementById("song-select")
var cat = this.songs[this.selectedSong].originalCategory || this.songs.find(song => song.action === "random").category
var cat = this.songs[this.selectedSong].originalCategory
this.drawBackground(cat)
this.previewId = 0
@ -407,7 +407,7 @@ class SongSelect{
if(cat){
this.drawBackground(cat)
}else{
this.drawBackground(this.songs.find(song => song.action === "random").category)
this.drawBackground(false)
}
}