mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-25 16:07:12 -07:00
More syntax fix.
This commit is contained in:
parent
05d0ff04fb
commit
e8dcfc6d4b
1 changed files with 2 additions and 2 deletions
|
@ -138,8 +138,8 @@ class GithubApi2 @Inject constructor(
|
|||
val releases = ex.body()
|
||||
if (releases != null) {
|
||||
releases.firstOrNull()?.let {
|
||||
try {
|
||||
result = listOf(it.name, it.tagName).filterNotNull().first { !it.isBlank() }
|
||||
result = try {
|
||||
listOf(it.name, it.tagName).filterNotNull().first { !it.isBlank() }
|
||||
} catch(ex: NoSuchElementException) {
|
||||
throw KobaltException("Couldn't find the latest release")
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue