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
{
26
foreach ($this->currencies as $currency) {
27
if ($currency['Code'] == $currencyCode) {
28
if ($currency['SymbolOnLeft'] == 'true') {
29
return $currency['Symbol'] .
30
number_format(
31
$price,
32
2,
33
$currency['DecimalSeparator'],
34
$currency['ThousandsSeparator']
35
);
36
}
37
38
return number_format(
39
$price,
40
2,
41
$currency['DecimalSeparator'],
42
$currency['ThousandsSeparator']
43
) . $currency['Symbol'];
44
}
45
}
46
}
47
48
/**
49
* @param $resourcesDir
50
*/
51
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.