This check compares the return type specified in the @return annotation of a function
or method doc comment with the types returned by the function and raises an issue if they
mismatch.
Loading history...
23
*/
24
public function format($price, $currencyCode) {
25
foreach ($this->currencies as $currency) {
26
if ($currency['Code'] == $currencyCode) {
27
if ($currency['SymbolOnLeft'] == 'true') {
28
return $currency['Symbol'] .
29
number_format(
30
$price,
31
2,
32
$currency['DecimalSeparator'],
33
$currency['ThousandsSeparator']
34
);
35
}
36
37
return number_format(
38
$price,
39
2,
40
$currency['DecimalSeparator'],
41
$currency['ThousandsSeparator']
42
) . $currency['Symbol'];
43
}
44
}
45
}
46
47
/**
48
* @param $resourcesDir
49
*/
50
private function initializeCurrenciesFile($resourcesDir)
This check compares the return type specified in the
@return
annotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.