| Conditions | 1 |
| Paths | 1 |
| Total Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 1 |
| Changes | 0 | ||
| 1 | <?php namespace Propaganistas\LaravelPhone\Exceptions; |
||
| 24 | 33 | public static function countryRequired($number) |
|
| 25 | { |
||
| 26 | 33 | $exception = new static( |
|
| 27 | 33 | libNumberParseException::INVALID_COUNTRY_CODE, |
|
| 28 | 33 | 'Number requires a country to be specified.' |
|
| 29 | ); |
||
| 30 | |||
| 31 | 33 | $exception->number = $number; |
|
| 32 | |||
| 33 | 33 | return $exception; |
|
| 34 | } |
||
| 35 | |||
| 73 | } |
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.