| Conditions | 3 |
| Paths | 3 |
| Total Lines | 11 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 7 |
| CRAP Score | 3 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 18 | 6 | public function __construct(Segments $segments) |
|
| 19 | { |
||
| 20 | 6 | foreach ($segments->all() as $segment) { |
|
| 21 | 4 | if (false === $segment instanceof IdentitySegment) { |
|
| 22 | 1 | throw new InvalidArgumentException(sprintf( |
|
| 23 | 1 | 'Enable by matching identity id segment must be instance of %s class.', |
|
| 24 | 1 | IdentitySegment::class |
|
| 25 | )); |
||
| 26 | } |
||
| 27 | } |
||
| 28 | 5 | $this->segments = $segments; |
|
| 29 | 5 | } |
|
| 61 |