From 7281ba447d4c0cd05b9cb859d6f14e0a060fcb3e Mon Sep 17 00:00:00 2001 From: Matthias Schmidt Date: Sat, 7 Jul 2018 17:22:26 +0200 Subject: [PATCH] Fix `SingleSelectionFormField::validate()` See #2509 --- .../form/builder/field/SingleSelectionFormField.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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}'"); } -- 2.20.1