Skip to content

Commit

Permalink
Version bumps to fix Discord bug
Browse files Browse the repository at this point in the history
  • Loading branch information
DRSchlaubi committed Jan 23, 2024
1 parent 9058127 commit 15edfc2
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 27 deletions.
2 changes: 1 addition & 1 deletion .idea/kotlinc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plugins {
alias(libs.plugins.kotlin.serialization) apply false
}
allprojects {
version = "5.3.0"
version = "5.3.1"
group = "space.votebot"

repositories {
Expand Down
10 changes: 5 additions & 5 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[versions]
kotlin = "1.9.20"
mikbot = "3.25.1"
ktor = "2.3.6"
kotlin = "1.9.22"
mikbot = "3.28.0"
ktor = "2.3.4"

[libraries]
kotlinx-serialization-json = { group = "org.jetbrains.kotlinx", name = "kotlinx-serialization-json", version = "1.6.0" }
kotlinx-serialization-json = { group = "org.jetbrains.kotlinx", name = "kotlinx-serialization-json", version = "1.6.1" }
ktor-client-okhttp = { group = "io.ktor", name = "ktor-client-okhttp", version.ref = "ktor" }
ktor-client-content-negotiation = { group = "io.ktor", name = "ktor-client-content-negotiation", version.ref = "ktor" }
ktor-serialization-kotlinx-json = { group = "io.ktor", name = "ktor-serialization-kotlinx-json", version.ref = "ktor" }
Expand All @@ -19,5 +19,5 @@ java-string-similarity = { group = "info.debatty", name = "java-string-similarit
kotlin = { id = "org.jetbrains.kotlin.jvm", version.ref = "kotlin" }
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", version.ref = "kotlin" }
mikbot = { id = "dev.schlaubi.mikbot.gradle-plugin", version.ref = "mikbot" }
ksp = { id = "com.google.devtools.ksp", version = "1.9.20-1.0.13" }
ksp = { id = "com.google.devtools.ksp", version = "1.9.22-1.0.16" }
buildconfig = { id = "com.github.gmazzo.buildconfig", version = "4.1.2"}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package space.votebot.commands.vote

import com.kotlindiscord.kord.extensions.extensions.publicSlashCommand
import dev.kord.rest.builder.message.create.embed
import dev.kord.rest.builder.message.embed
import dev.schlaubi.mikbot.plugin.api.MikBotInfo
import dev.schlaubi.stdx.coroutines.parallelMapNotNull
import io.ktor.client.*
Expand Down
18 changes: 0 additions & 18 deletions plugin/src/main/kotlin/space/votebot/core/Plugin.kt
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,9 @@ import com.kotlindiscord.kord.extensions.builders.ExtensibleBotBuilder
import com.kotlindiscord.kord.extensions.extensions.Extension
import com.kotlindiscord.kord.extensions.extensions.event
import dev.kord.core.event.gateway.ReadyEvent
import dev.kord.gateway.PrivilegedIntent
import dev.schlaubi.mikbot.plugin.api.Plugin
import dev.schlaubi.mikbot.plugin.api.PluginContext
import dev.schlaubi.mikbot.plugin.api.PluginMain
import dev.schlaubi.mikbot.plugin.api.config.Config
import dev.schlaubi.mikbot.plugin.api.config.Environment
import io.ktor.client.*
import io.ktor.client.engine.cio.*
import kotlinx.coroutines.cancel
import kotlinx.serialization.builtins.serializer
import org.litote.kmongo.serialization.registerSerializer
Expand All @@ -23,19 +18,6 @@ class VoteBotPlugin(wrapper: PluginContext) : Plugin(wrapper) {
registerSerializer(ULong.serializer())
}

@OptIn(PrivilegedIntent::class)
override suspend fun ExtensibleBotBuilder.apply() {
if (Config.ENVIRONMENT == Environment.PRODUCTION) {
kord {
httpClient = HttpClient(CIO) {
engine {
threadsCount = 25
}
}
}
}
}

override fun ExtensibleBotBuilder.ExtensionsBuilder.addExtensions() {
add(::VoteBotModule)
}
Expand Down

0 comments on commit 15edfc2

Please sign in to comment.