Commit c93958fa authored by Ad Schellevis's avatar Ad Schellevis

(legacy) add is_apinger_enabled function

parent 482a25c3
......@@ -1069,4 +1069,24 @@ function gateway_is_gwgroup_member($name) {
return $members;
}
/**
* check if apinger service is enabled
*/
function is_apinger_enabled() {
global $config;
$gwcount=0;
foreach($config['gateways']['gateway_item'] as $gwkey => $gateway) {
if (!isset($gateway['monitor_disable']) || $gateway['monitor_disable'] == "0") {
$gwcount += 1;
}
}
if ($gwcount == 0) {
return false;
} else {
return true;
}
}
?>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment