From: Alexander Ebert Date: Fri, 2 Dec 2011 19:27:38 +0000 (+0100) Subject: Users can now be added through ACP again X-Git-Tag: 2.0.0_Beta_1~1540 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=f4d0ce5a696b5edab831d0f4be504ced67309de1;p=GitHub%2FWoltLab%2FWCF.git Users can now be added through ACP again Fixes #273 --- diff --git a/wcfsetup/install/files/lib/system/option/user/UserOptionHandler.class.php b/wcfsetup/install/files/lib/system/option/user/UserOptionHandler.class.php index ee50ce3690..5718f999ae 100644 --- a/wcfsetup/install/files/lib/system/option/user/UserOptionHandler.class.php +++ b/wcfsetup/install/files/lib/system/option/user/UserOptionHandler.class.php @@ -72,7 +72,9 @@ class UserOptionHandler extends OptionHandler { $optionData = parent::getOption($optionName); $optionData['object'] = new ViewableUserOption($optionData['object']); - $optionData['object']->setOptionValue($this->user); + if ($this->user !== null) { + $optionData['object']->setOptionValue($this->user); + } if ($this->removeEmptyOptions && empty($optionData['object']->optionValue)) { return null; @@ -107,7 +109,9 @@ class UserOptionHandler extends OptionHandler { * @see wcf\system\option\OptionHandler::checkVisibility() */ protected function checkVisibility(Option $option) { - $option->setUser($this->user); + if ($this->user !== null) { + $option->setUser($this->user); + } return $option->isVisible(); }