Fixed polling ports so that NULL values don't break stuff. Basically I just have a foreach loop to unset any NULL values. Also fixed the NOW() SQL statements at the end of polling.

This commit is contained in:
mchasteen
2015-02-16 16:33:56 -07:00
committed by laf
parent d7ea7e71bf
commit 87bd0da996
2 changed files with 8 additions and 2 deletions
+6
View File
@@ -430,6 +430,12 @@ foreach ($ports as $port)
$memcache->set('port-'.$port['port_id'].'-state', $port['state']);
}
foreach ($port['update'] as $key => $val_check){
if (!isset($val_check)) {
unset($port['update'][$key]);
}
}
// Update Database
if (count($port['update']))
{