We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4fe386e commit d5b47e3Copy full SHA for d5b47e3
app/src/main/kotlin/me/rhunk/snapenhance/ui/manager/data/Updater.kt
@@ -41,7 +41,7 @@ object Updater {
41
JsonParser.parseString(it.body.string()).asJsonObject
42
}
43
val debugRuns = actionRuns.getAsJsonArray("workflow_runs")?.mapNotNull { it.asJsonObject }?.filter { run ->
44
- run.getAsJsonPrimitive("conclusion")?.asString == "success" && run.getAsJsonPrimitive("path")?.asString == ".github/workflows/debug.yml"
+ run.get("conclusion")?.takeIf { it.isJsonPrimitive }?.asString == "success" && run.getAsJsonPrimitive("path")?.asString == ".github/workflows/debug.yml"
45
} ?: throw Throwable("No debug CI runs found")
46
47
val latestRun = debugRuns.firstOrNull() ?: throw Throwable("No debug CI runs found")
0 commit comments