Feature Major updates and bug fixes
Some checks failed
Locusworks Team/eight-track/pipeline/head There was a failure building this commit

#4 Added logic to disconnect the bot if no song is playing or no one is
listening

#10 Added functionality to play song from local source and ability to
upload songs

#10 No longer cashes songs in memory but queries the database for random
song

#10 Whatsnext will push a song on the queue if it doesn't exist

#10 Next will get a random song from the database
This commit is contained in:
Isaac Parenteau
2019-10-07 23:48:05 -05:00
parent fe4c25cc4c
commit 2ac25f64aa
6 changed files with 92 additions and 72 deletions

View File

@@ -50,4 +50,7 @@ public interface GuildSongRepository extends CrudRepository<GuildSong, Long> {
@Query("SELECT gs FROM GuildSong gs WHERE gs.guild.guildId = ?1")
List<GuildSong> findByGuild(Long guildId);
@Query("SELECT gs FROM GuildSong gs WHERE gs.guild.guildId = ?1 ORDER BY RAND()")
List<GuildSong> findRandomSong(Long guildId);
}