| Conditions | 5 |
| Paths | 4 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 7 |
| CRAP Score | 5.0488 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 27 | 2 | public function matchToBeDefined(mixed $input): bool |
|
| 28 | { |
||
| 29 | 2 | if (! is_scalar($input) && ! is_null($input)) { |
|
| 30 | return false; |
||
| 31 | } |
||
| 32 | |||
| 33 | 2 | $input = trim(strval($input)); |
|
| 34 | 2 | foreach ($this->toBeDefinedTexts as $toBeDefinedText) { |
|
| 35 | 2 | if (0 === strcasecmp($toBeDefinedText, $input)) { |
|
| 36 | 2 | return true; |
|
| 37 | } |
||
| 38 | } |
||
| 39 | 1 | return false; |
|
| 40 | } |
||
| 42 |