From: Matthias Schmidt Date: Sat, 7 Jul 2018 15:22:26 +0000 (+0200) Subject: Fix `SingleSelectionFormField::validate()` X-Git-Tag: 5.2.0_Alpha_1~680^2~23 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=7281ba447d4c0cd05b9cb859d6f14e0a060fcb3e;p=GitHub%2FWoltLab%2FWCF.git Fix `SingleSelectionFormField::validate()` See #2509 --- diff --git a/wcfsetup/install/files/lib/system/form/builder/field/SingleSelectionFormField.class.php b/wcfsetup/install/files/lib/system/form/builder/field/SingleSelectionFormField.class.php index 8690a66502..7e542a628b 100644 --- a/wcfsetup/install/files/lib/system/form/builder/field/SingleSelectionFormField.class.php +++ b/wcfsetup/install/files/lib/system/form/builder/field/SingleSelectionFormField.class.php @@ -71,7 +71,7 @@ class SingleSelectionFormField extends AbstractFormField implements INullableFor return $this; } - if (!isset($this->getOptions()[$this->getValue()])) { + if (!isset($this->getOptions()[$value])) { throw new \InvalidArgumentException("Unknown value '{$value}'"); }