| Conditions | 4 |
| Paths | 4 |
| Total Lines | 13 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 4 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php namespace BuildR\Collection\Collection; |
||
| 56 | 82 | protected function doTypeCheck($value) { |
|
| 57 | 82 | if($this->isStrict()) { |
|
| 58 | 3 | $result = (bool) call_user_func_array($this->typeChecker, [$value]); |
|
| 59 | |||
| 60 | 3 | if($result === FALSE) { |
|
| 61 | 2 | $message = ($this->typeCheckFailMessage === NULL) ? gettype($value) : $this->typeCheckFailMessage; |
|
| 62 | |||
| 63 | 2 | throw CollectionException::typeException($message); |
|
| 64 | } |
||
| 65 | |||
| 66 | 1 | return TRUE; |
|
| 67 | } |
||
| 68 | 79 | } |
|
| 69 | |||
| 71 |