From: Thalia Date: Thu, 18 Jul 2019 14:48:09 +0000 (+0100) Subject: Allow empty input in namespaces multiselect on Special:Block X-Git-Tag: 1.34.0-rc.0~948^2 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/exercices/journal.php?a=commitdiff_plain;h=ffcb5928e119d5d428edc9171e6000780bd4fdf3;p=lhc%2Fweb%2Fwiklou.git Allow empty input in namespaces multiselect on Special:Block Follow-up to 83ebbb519f Bug: T219882 Change-Id: I5f3d907a8f8be02f9e2c23d2a66c42752daa38b5 --- diff --git a/includes/htmlform/fields/HTMLNamespacesMultiselectField.php b/includes/htmlform/fields/HTMLNamespacesMultiselectField.php index cbcd3ba34b..860a351c10 100644 --- a/includes/htmlform/fields/HTMLNamespacesMultiselectField.php +++ b/includes/htmlform/fields/HTMLNamespacesMultiselectField.php @@ -28,7 +28,7 @@ class HTMLNamespacesMultiselectField extends HTMLSelectNamespace { } public function validate( $value, $alldata ) { - if ( !$this->mParams['exists'] ) { + if ( !$this->mParams['exists'] || $value === '' ) { return true; }