Conditions | 4 |
Paths | 4 |
Total Lines | 13 |
Code Lines | 7 |
Lines | 0 |
Ratio | 0 % |
Tests | 2 |
CRAP Score | 10.75 |
Changes | 3 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
42 | 54 | public function checkSignatures(ConsensusInterface $consensus, array $outputs) |
|
43 | { |
||
44 | if (count($this->transaction->getInputs()) !== count($outputs)) { |
||
45 | throw new \InvalidArgumentException('Incorrect scriptPubKey count'); |
||
46 | } |
||
47 | |||
48 | 54 | $result = true; |
|
49 | foreach ($outputs as $i => $txOut) { |
||
50 | $result = $result && $this->checkSignature($consensus, $i, $txOut); |
||
51 | } |
||
52 | |||
53 | return $result; |
||
54 | } |
||
55 | } |
||
56 |