Skip to content

Commit

Permalink
Merge pull request #424 from KittyBot-Org/development
Browse files Browse the repository at this point in the history
spotify playlist bug fix
  • Loading branch information
topi314 authored Sep 7, 2021
2 parents 83ad187 + fa0c200 commit f25c97f
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 17 deletions.
26 changes: 13 additions & 13 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ plugins {
id 'java'
id 'application'
id 'com.github.johnrengelman.shadow' version '7.0.0'
id 'nu.studer.jooq' version '6.0'
id 'nu.studer.jooq' version '6.0.1'
}

group 'de.kittybot'
Expand All @@ -17,12 +17,12 @@ repositories {

dependencies {
// discord/jda related
implementation('net.dv8tion:JDA:4.3.0_306') {
implementation('net.dv8tion:JDA:4.3.0_323') {
exclude group: 'club.minnced', module: 'opus-java'
}
implementation 'com.jagrosh:jda-utilities:3.0.5'
implementation 'club.minnced:discord-webhooks:0.5.8'
implementation 'dev.mlnr:BotListHandler-jda:2.0.0_8'
implementation 'dev.mlnr:BotListHandler-jda:2.0.0_11'

// audio
implementation('com.github.KittyBot-Org:Lavalink-Client:d48f1a6') {
Expand All @@ -33,36 +33,36 @@ dependencies {

// database
implementation 'com.zaxxer:HikariCP:5.0.0'
implementation 'org.jooq:jooq:3.15.1'
implementation 'org.jooq:jooq:3.15.2'
implementation 'org.postgresql:postgresql:42.2.23'
jooqGenerator 'org.postgresql:postgresql:42.2.23'

// logging
implementation 'ch.qos.logback:logback-classic:1.3.0-alpha6'
implementation 'io.sentry:sentry-logback:5.0.1'
implementation 'ch.qos.logback:logback-classic:1.3.0-alpha10'
implementation 'io.sentry:sentry-logback:5.1.2'

// eval
implementation 'org.codehaus.groovy:groovy-jsr223:3.0.8'
implementation 'org.codehaus.groovy:groovy-jsr223:3.0.9'

// jjwt
implementation 'io.jsonwebtoken:jjwt-api:0.11.2'
implementation 'io.jsonwebtoken:jjwt-impl:0.11.2'
implementation 'io.jsonwebtoken:jjwt-jackson:0.11.2'

// Prometheus
implementation 'io.prometheus:simpleclient:0.11.0'
implementation 'io.prometheus:simpleclient_hotspot:0.11.0'
implementation 'io.prometheus:simpleclient_httpserver:0.11.0'
implementation 'io.prometheus:simpleclient:0.12.0'
implementation 'io.prometheus:simpleclient_hotspot:0.12.0'
implementation 'io.prometheus:simpleclient_httpserver:0.12.0'

// other
implementation 'io.javalin:javalin:3.13.10'
implementation 'io.github.classgraph:classgraph:4.8.111'
implementation 'io.javalin:javalin:3.13.11'
implementation 'io.github.classgraph:classgraph:4.8.115'
implementation 'com.github.ben-manes.caffeine:caffeine:3.0.3'
implementation 'com.squareup.okhttp3:okhttp:4.9.1'
}

jooq {
version = '3.14.12'
version = '3.15.2'
configurations {
main {
generateSchemaSourceOnCompilation = false
Expand Down
4 changes: 3 additions & 1 deletion src/main/java/de/kittybot/kittybot/main/KittyBot.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,13 @@ public KittyBot() throws IOException, MissingConfigValuesException, LoginExcepti
var modules = new Modules(this);
var botListHandler = new BLHBuilder()
.setUnavailableEventsEnabled(false)
.setDevModePredicate(jda -> Environment.is(Environment.DEVELOPMENT))
.setDevModePredicate(id -> Environment.is(Environment.DEVELOPMENT))
.setSuccessLoggingEnabled(false)
.setErrorLoggingThreshold(2)
.addBotList(BotList.TOP_GG, Config.TOP_GG_TOKEN)
.addBotList(BotList.DBOATS, Config.DISCORD_BOATS_TOKEN)
.addBotList(BotList.DISCORDLIST_SPACE, Config.BOTLIST_SPACE_TOKEN)
.addBotList(BotList.DISCORDS, Config.BOTS_FOR_DISCORD_TOKEN)
.addBotList(BotList.DSERVICES, Config.DISCORD_SERVICES_TOKEN)
.addBotList(BotList.DBL, Config.DISCORD_BOT_LIST_TOKEN)
.addBotList(BotList.DEL, Config.DISCORD_EXTREME_LIST_TOKEN)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ public void destroy(MusicManager musicManager, String reason){
if(channel == null || !channel.canTalk()){
return;
}
channel.sendMessage(new EmbedBuilder().setColor(Color.RED).setDescription(reason).setTimestamp(Instant.now()).build()).queue();
channel.sendMessageEmbeds(new EmbedBuilder().setColor(Color.RED).setDescription(reason).setTimestamp(Instant.now()).build()).queue();
}
}

Expand Down
4 changes: 2 additions & 2 deletions src/main/java/de/kittybot/kittybot/modules/SpotifyModule.java
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ private void loadAlbum(String id, GuildInteraction ia, MusicManager manager){
var items = tracks.getItems();
var toLoad = new ArrayList<String>();
for(var track : items){
toLoad.add("ytsearch:" + track.getArtists()[0].getName() + " " + track.getName());
toLoad.add(track.getArtists()[0].getName() + " " + track.getName());
}
loadTracks(id, ia, manager, toLoad);
}).exceptionally(throwable -> {
Expand All @@ -97,7 +97,7 @@ private void loadPlaylist(String id, GuildInteraction ia, MusicManager manager){
var toLoad = new ArrayList<String>();
for(var item : items){
var track = (Track) item.getTrack();
toLoad.add("ytsearch:" + track.getArtists()[0].getName() + " " + track.getName());
toLoad.add(track.getArtists()[0].getName() + " " + track.getName());
}
loadTracks(id, ia, manager, toLoad);
}).exceptionally(throwable -> {
Expand Down

0 comments on commit f25c97f

Please sign in to comment.