mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 08:44:10 +02:00
ProcessCheckResultCommandForm: Use substr instead of pregmatch
refs #9672
This commit is contained in:
parent
18f382e85e
commit
b5ae4599fd
@ -124,7 +124,7 @@ class ProcessCheckResultCommandForm extends ObjectsCommandForm
|
||||
ProcessCheckResultCommand::HOST_DOWN => $this->translate('DOWN', 'icinga.state')
|
||||
);
|
||||
|
||||
if (! preg_match('~^v2\.\d+\.\d+.*$~', $this->getBackend()->getProgramVersion())) {
|
||||
if (substr($this->getBackend()->getProgramVersion(), 0, 2) !== 'v2') {
|
||||
$options[ProcessCheckResultCommand::HOST_UNREACHABLE] = $this->translate('UNREACHABLE', 'icinga.state');
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user