diff options
author | Simon Rettberg | 2017-06-07 14:12:12 +0200 |
---|---|---|
committer | Simon Rettberg | 2017-06-07 14:12:12 +0200 |
commit | 963c2b7b8b7d1e54ac9fb770239d2a4673f9b66e (patch) | |
tree | 9d54fdd6ace77f0844094bc8538e781330d79c1d /modules-available/statistics | |
parent | [locationinfo] Change order of status bars in overview frontend (diff) | |
download | slx-admin-963c2b7b8b7d1e54ac9fb770239d2a4673f9b66e.tar.gz slx-admin-963c2b7b8b7d1e54ac9fb770239d2a4673f9b66e.tar.xz slx-admin-963c2b7b8b7d1e54ac9fb770239d2a4673f9b66e.zip |
[statistics] Float cannot be array index
Diffstat (limited to 'modules-available/statistics')
-rw-r--r-- | modules-available/statistics/page.inc.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules-available/statistics/page.inc.php b/modules-available/statistics/page.inc.php index 5ad8bc20..2b12c69f 100644 --- a/modules-available/statistics/page.inc.php +++ b/modules-available/statistics/page.inc.php @@ -404,7 +404,7 @@ class Page_Statistics extends Page $res = Database::simpleQuery("SELECT mbram, Count(*) AS `count` FROM machine $join WHERE $where GROUP BY mbram", $args); $lines = array(); while ($row = $res->fetch(PDO::FETCH_ASSOC)) { - $gb = ceil($row['mbram'] / 1024); + $gb = (int)ceil($row['mbram'] / 1024); for ($i = 1; $i < count($SIZE_RAM); ++$i) { if ($SIZE_RAM[$i] < $gb) { continue; @@ -476,7 +476,7 @@ class Page_Statistics extends Page $total = 0; while ($row = $res->fetch(PDO::FETCH_ASSOC)) { $total += $row['count']; - $gb = ceil($row['id44mb'] / 1024); + $gb = (int)ceil($row['id44mb'] / 1024); for ($i = 1; $i < count($SIZE_ID44); ++$i) { if ($SIZE_ID44[$i] < $gb) { continue; |