mirror of
https://github.com/corda/corda.git
synced 2025-01-19 03:06:36 +00:00
Change "size > 0" to isNotEmpty()
This commit is contained in:
parent
6c6ed3a758
commit
39ca3c96f9
@ -160,8 +160,8 @@ class Obligation<P : Any> : Contract {
|
||||
.filter { it.amount.token in template.acceptableIssuedProducts }
|
||||
// Catch that there's nothing useful here, so we can dump out a useful error
|
||||
requireThat {
|
||||
"there are fungible asset state outputs" using (assetStates.size > 0)
|
||||
"there are defined acceptable fungible asset states" using (acceptableAssetStates.size > 0)
|
||||
"there are fungible asset state outputs" using (assetStates.isNotEmpty())
|
||||
"there are defined acceptable fungible asset states" using (acceptableAssetStates.isNotEmpty())
|
||||
}
|
||||
|
||||
val amountReceivedByOwner = acceptableAssetStates.groupBy { it.owner }
|
||||
|
Loading…
Reference in New Issue
Block a user