mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-30 17:24:16 +02:00
monitoring: Fix Icinga 2 version detection in the toggle object features command form
This commit is contained in:
parent
4df7fdea88
commit
9bc9b78643
@ -59,7 +59,7 @@ class ToggleObjectFeaturesCommandForm extends ObjectsCommandForm
|
|||||||
'permission' => 'monitoring/command/feature/object/flap-detection'
|
'permission' => 'monitoring/command/feature/object/flap-detection'
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
if (preg_match('~^v2\.\d+\.\d+.*$~', $this->getIcingaVersion())) {
|
if (preg_match('~^[vr]2\.\d+\.\d+.*$~', $this->getIcingaVersion())) {
|
||||||
unset($features[ToggleObjectFeatureCommand::FEATURE_OBSESSING]);
|
unset($features[ToggleObjectFeatureCommand::FEATURE_OBSESSING]);
|
||||||
}
|
}
|
||||||
$this->features = $features;
|
$this->features = $features;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user