Confirmed. I get the same error when modifying proxy. I must have been looking on a wrong server…
I think the error does no harm and a fix is more or less cosmetic and main focus is on cockpit now.
Because there are no proxy rules, the array is empty and that throws the error.
I added a check and the error seems to not occur anymore but I didn’t test much and don’t know if that change has other negative impacts.
I edited /usr/share/nethesis/NethServer/Module/Proxy/Rules/Modify.php
:
Line 129:
private function nextKey()
{
$db = $this->getPlatform()->getDatabase('squid');
$array = array_keys($db->getAll('rule'));
if(!empty($array)) $max = max($array);
return $max+1;
}