mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-27 07:44:04 +02:00
AuthBackendPage: Do only create a resource config if necessary
This commit is contained in:
parent
3b63868ed9
commit
f0d7629209
@ -121,7 +121,7 @@ class AuthBackendPage extends Form
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (false === isset($data['skip_validation']) || $data['skip_validation'] == 0) {
|
if ($this->config['type'] === 'ldap' && ( !isset($data['skip_validation']) || $data['skip_validation'] == 0)) {
|
||||||
$self = clone $this;
|
$self = clone $this;
|
||||||
$self->addElement(
|
$self->addElement(
|
||||||
'text',
|
'text',
|
||||||
@ -130,7 +130,7 @@ class AuthBackendPage extends Form
|
|||||||
'value' => $this->getResourceConfig()
|
'value' => $this->getResourceConfig()
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
if ($this->config['type'] === 'ldap' && false === LdapBackendForm::isValidUserBackend($self)) {
|
if (! LdapBackendForm::isValidUserBackend($self)) {
|
||||||
$this->addSkipValidationCheckbox();
|
$this->addSkipValidationCheckbox();
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user