From 0bc0589d24b9667028b6c3b63b0b08ff74b3eca2 Mon Sep 17 00:00:00 2001 From: julia-zack Date: Wed, 16 Oct 2024 14:43:30 -0300 Subject: [PATCH] Fix sonar complain --- .../src/test/java/co/rsk/peg/bitcoin/BitcoinTestUtils.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rskj-core/src/test/java/co/rsk/peg/bitcoin/BitcoinTestUtils.java b/rskj-core/src/test/java/co/rsk/peg/bitcoin/BitcoinTestUtils.java index de44e859fe..bd1cf8007c 100644 --- a/rskj-core/src/test/java/co/rsk/peg/bitcoin/BitcoinTestUtils.java +++ b/rskj-core/src/test/java/co/rsk/peg/bitcoin/BitcoinTestUtils.java @@ -160,13 +160,13 @@ private static void signLegacyTransactionInputFromP2shMultiSig(BtcTransaction tr public static List generateTransactionInputsSigHashes(BtcTransaction btcTx) { return IntStream.range(0, btcTx.getInputs().size()) .mapToObj(i -> generateSigHashForP2SHTransactionInput(btcTx, i)) - .collect(Collectors.toList()); + .toList(); } public static List generateSignerEncodedSignatures(BtcECKey signingKey, List sigHashes) { return sigHashes.stream() .map(signingKey::sign) .map(BtcECKey.ECDSASignature::encodeToDER) - .collect(Collectors.toList()); + .toList(); } }