private function formatMetrics(&$metrics)
{
$formatter = NumberFormatter::getInstance();
foreach ($metrics as $metricName => &$value) {
if (in_array($metricName, $this->displayedMetricColumns)) {
if (strpos($metricName, 'revenue') !== false) {
$currency = isset($metrics['idsite']) ? Site::getCurrencySymbolFor($metrics['idsite']) : '';
$value = $formatter->formatCurrency($value, $currency);
continue;
}
$value = $formatter->format($value);
}
}
}