Conditions | 5 |
Paths | 4 |
Total Lines | 14 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 5.0488 |
Changes | 2 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
47 | { |
||
48 | 14 | foreach ($this->commentTypes as $commentType) { |
|
49 | 14 | if (! $commentType->matchesPattern($token)) { |
|
50 | 12 | continue; |
|
51 | } |
||
52 | if ( |
||
53 | 14 | empty($this->allowedTypes) |
|
54 | 14 | || in_array($commentType->getName(), $this->allowedTypes, true) |
|
55 | ) { |
||
56 | 14 | return $commentType; |
|
57 | } |
||
58 | } |
||
59 | return null; |
||
60 | } |
||
61 | } |
||
62 |