Skip to content

Commit d4e9862

Browse files
committed
Attempt a fix for the bot dying
1 parent 29f734a commit d4e9862

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ plugins {
3535
id("org.jmailen.kotlinter") version "3.5.1"
3636
}
3737

38-
val numberVersion = "3.106.3"
38+
val numberVersion = "3.106.4"
3939

4040
project.group = "ml.duncte123.skybot"
4141
project.version = "${numberVersion}_${getGitHash()}"

src/main/kotlin/ml/duncte123/skybot/adapters/DatabaseAdapter.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ abstract class DatabaseAdapter(threads: Int = 2) {
243243
}
244244

245245
// Cannot be an option callback due to it targeting the onFail param
246-
/*protected fun runOnThread(r: () -> Unit, onFail: (Throwable) -> Unit = {}) {
246+
protected fun runOnThread(r: () -> Unit, onFail: (Throwable) -> Unit) {
247247
databaseThread.execute {
248248
try {
249249
r.invoke()
@@ -253,9 +253,9 @@ abstract class DatabaseAdapter(threads: Int = 2) {
253253
thr.printStackTrace()
254254
}
255255
}
256-
}*/
256+
}
257257

258-
protected fun runOnThread(r: () -> Unit, onFail: (Throwable) -> Unit) = runBlocking {
258+
/*protected fun runOnThread(r: () -> Unit, onFail: (Throwable) -> Unit) = runBlocking {
259259
launch {
260260
try {
261261
r.invoke()
@@ -265,5 +265,5 @@ abstract class DatabaseAdapter(threads: Int = 2) {
265265
thr.printStackTrace()
266266
}
267267
}
268-
}
268+
}*/
269269
}

0 commit comments

Comments
 (0)