mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
check if the proper variable is empty (#10017)
This commit is contained in:
@@ -77,7 +77,7 @@ $component = new LibreNMS\Component();
|
|||||||
$f2b_components = $component->getComponents($device_id, $options);
|
$f2b_components = $component->getComponents($device_id, $options);
|
||||||
|
|
||||||
// if no jails, delete fail2ban components
|
// if no jails, delete fail2ban components
|
||||||
if (empty($jails)) {
|
if (empty($f2b['jails'])) {
|
||||||
if (isset($f2b_components[$device_id])) {
|
if (isset($f2b_components[$device_id])) {
|
||||||
foreach ($f2b_components[$device_id] as $component_id => $_unused) {
|
foreach ($f2b_components[$device_id] as $component_id => $_unused) {
|
||||||
$component->deleteComponent($component_id);
|
$component->deleteComponent($component_id);
|
||||||
|
Reference in New Issue
Block a user