diff options
author | Simon Rettberg | 2014-06-11 14:31:09 +0200 |
---|---|---|
committer | Simon Rettberg | 2014-06-11 14:31:09 +0200 |
commit | 62d6349c790076ec26edd6e10d617b2f4c385e8b (patch) | |
tree | b2884200b75b34994ddfcfef06bff3d127427e73 /modules/systemstatus.inc.php | |
parent | Reboot functionality on system status page (diff) | |
download | slx-admin-62d6349c790076ec26edd6e10d617b2f4c385e8b.tar.gz slx-admin-62d6349c790076ec26edd6e10d617b2f4c385e8b.tar.xz slx-admin-62d6349c790076ec26edd6e10d617b2f4c385e8b.zip |
Minor bug fixes and removal of dead code
Diffstat (limited to 'modules/systemstatus.inc.php')
-rw-r--r-- | modules/systemstatus.inc.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/systemstatus.inc.php b/modules/systemstatus.inc.php index bfef54ef..a83a8919 100644 --- a/modules/systemstatus.inc.php +++ b/modules/systemstatus.inc.php @@ -9,6 +9,7 @@ class Page_SystemStatus extends Page User::load(); if (!User::isLoggedIn()) { + Message::addError('no-permission'); Util::redirect('?do=Main'); } @@ -153,6 +154,7 @@ class Page_SystemStatus extends Page $total = $out['user'] + $out['nice'] + $out['system'] + $out['idle'] + $out['iowait'] + $out['irq'] + $out['softirq']; $data['cpuLoad'] = 100 - round(($out['idle'] / $total) * 100); $data['cpuSystem'] = round((($out['iowait'] + $out['irq'] + $out['softirq']) / $total) * 100); + $data['cpuLoadOk'] = true; } echo Render::parse('systemstatus/systeminfo', $data); } |