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