mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-13 08:54:51 +02:00
Adding delete_agent control for meta
This commit is contained in:
parent
3b9558c7a0
commit
e300f2244d
@ -1885,11 +1885,17 @@ function api_set_delete_agent($id, $thrash1, $other, $thrash3)
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// Delete only if the centralised mode is disabled.
|
// Delete only if the centralised mode is disabled.
|
||||||
if (is_central_policies_on_node()) {
|
$headers = getallheaders();
|
||||||
|
if (!isset($headers['idk']) || !is_management_allowed($headers['idk'])) {
|
||||||
returnError('centralized');
|
returnError('centralized');
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Support for Pandora Enterprise.
|
||||||
|
if (license_free() === false) {
|
||||||
|
define('PANDORA_ENTERPRISE', true);
|
||||||
|
}
|
||||||
|
|
||||||
if ($agent_by_alias) {
|
if ($agent_by_alias) {
|
||||||
$idsAgents = agents_get_agent_id_by_alias(io_safe_input($id));
|
$idsAgents = agents_get_agent_id_by_alias(io_safe_input($id));
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user