mirror of
https://github.com/corda/corda.git
synced 2024-12-28 00:38:55 +00:00
Another simple code review tweak.
This commit is contained in:
parent
34797c2735
commit
ec9ecc88cc
@ -14,7 +14,6 @@ import net.corda.client.model.Models
|
||||
import net.corda.client.model.observableValue
|
||||
import net.corda.core.contracts.GBP
|
||||
import net.corda.core.contracts.USD
|
||||
import net.corda.core.messaging.startFlow
|
||||
import net.corda.core.node.services.ServiceInfo
|
||||
import net.corda.core.node.services.ServiceType
|
||||
import net.corda.explorer.model.CordaViewModel
|
||||
@ -89,12 +88,8 @@ class Main : App(MainView::class) {
|
||||
}
|
||||
|
||||
private fun asInteger(s: String?): Int? {
|
||||
if (s == null) {
|
||||
return null
|
||||
}
|
||||
|
||||
try {
|
||||
return s.toInt()
|
||||
return s?.toInt()
|
||||
} catch (e: NumberFormatException) {
|
||||
return null
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user