From e823e11e8542d4271cf777c70a2df88443183c4d Mon Sep 17 00:00:00 2001 From: Katarzyna Streich Date: Thu, 13 Oct 2016 18:16:00 +0100 Subject: [PATCH] Change places in code where instead of transaction id hash is used. --- .../kotlin/com/r3corda/core/transactions/SignedTransaction.kt | 2 +- test-utils/src/main/kotlin/com/r3corda/testing/TestDSL.kt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/src/main/kotlin/com/r3corda/core/transactions/SignedTransaction.kt b/core/src/main/kotlin/com/r3corda/core/transactions/SignedTransaction.kt index 67dbceee45..10040cd6fd 100644 --- a/core/src/main/kotlin/com/r3corda/core/transactions/SignedTransaction.kt +++ b/core/src/main/kotlin/com/r3corda/core/transactions/SignedTransaction.kt @@ -32,7 +32,7 @@ data class SignedTransaction(val txBits: SerializedBytes, val tx: WireTransaction by lazy { WireTransaction.deserialize(txBits) } /** A transaction ID is the hash of the [WireTransaction]. Thus adding or removing a signature does not change it. */ - override val id: SecureHash get() = txBits.hash + override val id: SecureHash get() = tx.id class SignaturesMissingException(val missing: Set, val descriptions: List, override val id: SecureHash) : NamedByHash, SignatureException() { override fun toString(): String { diff --git a/test-utils/src/main/kotlin/com/r3corda/testing/TestDSL.kt b/test-utils/src/main/kotlin/com/r3corda/testing/TestDSL.kt index 529b406819..d73bb6ad1d 100644 --- a/test-utils/src/main/kotlin/com/r3corda/testing/TestDSL.kt +++ b/test-utils/src/main/kotlin/com/r3corda/testing/TestDSL.kt @@ -250,7 +250,7 @@ data class TestLedgerDSLInterpreter private constructor ( labelToOutputStateAndRefs[label] = wireTransaction.outRef(index) } - transactionMap[wireTransaction.serialized.hash] = + transactionMap[wireTransaction.id] = WireTransactionWithLocation(transactionLabel, wireTransaction, transactionLocation) return wireTransaction