AHA!
Little nasty bug!
And anyway it's a SimplePortal bug, so...
Simple fix is to change in sources/subs/PortalBlocks.subs.php:
$totals += array(
'average_members' => comma_format(round($averages['registers'] / $total_days_up, 2)),
'average_posts' => comma_format(round($averages['posts'] / $total_days_up, 2)),
'average_topics' => comma_format(round($averages['topics'] / $total_days_up, 2)),
'average_online' => comma_format(round($averages['most_on'] / $total_days_up, 2)),
);
to:
$totals += array(
'average_members' => round($averages['registers'] / $total_days_up, 2),
'average_posts' => round($averages['posts'] / $total_days_up, 2),
'average_topics' => round($averages['topics'] / $total_days_up, 2),
'average_online' => round($averages['most_on'] / $total_days_up, 2),
);
Mostly unrelated: @Spuds do you think it would be hard to add the whole stack trace of functions (the function/class names should be mostly enough) to the error log?
The current one was designed to work with the monolithic structure of SMF with no more than two to five nested function calls, and I feel that the more we add functions, the more difficult is to track down where the actual problem is.