Conditions | 2 |
Paths | 2 |
Total Lines | 6 |
Code Lines | 3 |
Lines | 0 |
Ratio | 0 % |
Tests | 4 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
34 | 25 | public function __construct(string $protocolVersion) |
|
35 | { |
||
36 | 25 | if (in_array($protocolVersion, self::SUPPORTED_PROTOCOL_VERSIONS, true) === false) { |
|
37 | 1 | throw new UnacceptableProtocolVersion('The specified protocol is invalid'); |
|
38 | } |
||
39 | 24 | $this->protocolVersion = $protocolVersion; |
|
40 | 24 | } |
|
73 |