| Conditions | 1 |
| Paths | 1 |
| Total Lines | 12 |
| Code Lines | 7 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 24 | public static function camelCase($str) |
||
| 25 | { |
||
| 26 | // non-alpha and non-numeric characters become spaces |
||
| 27 | $str = preg_replace('/[^\w\d]+/', ' ', $str); |
||
| 28 | $str = trim($str); |
||
| 29 | // uppercase the first character of each word |
||
| 30 | $str = ucwords($str); |
||
| 31 | $str = str_replace(" ", "", $str); |
||
| 32 | $str = lcfirst($str); |
||
| 33 | |||
| 34 | return $str; |
||
| 35 | } |
||
| 36 | } |
||
| 37 |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italyis not defined by the methodfinale(...).The most likely cause is that the parameter was removed, but the annotation was not.