Conditions | 4 |
Paths | 4 |
Total Lines | 13 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 4 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
10 | 2 | public static function stringify($key) |
|
11 | 2 | { |
|
12 | 2 | static::initialize(); |
|
13 | 2 | if (is_int($key)) { |
|
14 | 2 | if (!isset(static::$intToStr[$key])) { |
|
15 | 2 | throw new \DomainException('Invalid cURL option number: ' . $key); |
|
16 | } |
||
17 | 2 | return static::$intToStr[$key]; |
|
18 | }; |
||
19 | 1 | if (!isset(static::$strToInt[$key])) { |
|
20 | 1 | throw new \DomainException('Invalid cURL option name: ' . $key); |
|
21 | } |
||
22 | 1 | return $key; |
|
23 | } |
||
66 |