mirror of
https://github.com/corda/corda.git
synced 2025-06-24 10:18:27 +00:00
Refactored NotaryChangeProtocol and tests: moved the proposal verification step into the protocol.
Added another proposal verification step in the NotaryChangeProtocol. Added the cause exception message to the 'notary change refused' error.
This commit is contained in:
@ -164,7 +164,7 @@ class Cash : FungibleAsset<Currency>() {
|
||||
throw InsufficientBalanceException(amount - gatheredAmount)
|
||||
|
||||
val change = if (takeChangeFrom != null && gatheredAmount > amount) {
|
||||
Amount<Issued<Currency>>(gatheredAmount.quantity - amount.quantity, takeChangeFrom.state.state.issuanceDef)
|
||||
Amount<Issued<Currency>>(gatheredAmount.quantity - amount.quantity, takeChangeFrom.state.data.issuanceDef)
|
||||
} else {
|
||||
null
|
||||
}
|
||||
|
Reference in New Issue
Block a user