From: Marcel Werk Date: Sun, 24 Feb 2019 15:27:31 +0000 (+0100) Subject: Prevent changing the field type of profile fields X-Git-Tag: 5.2.0_Alpha_1~267^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=8c78c4240ee88ade7e84abd25a357b4ffefb549d;p=GitHub%2FWoltLab%2FWCF.git Prevent changing the field type of profile fields Closes #2853 --- diff --git a/wcfsetup/install/files/acp/templates/userOptionAdd.tpl b/wcfsetup/install/files/acp/templates/userOptionAdd.tpl index d86ee27034..df8f6fcc1a 100644 --- a/wcfsetup/install/files/acp/templates/userOptionAdd.tpl +++ b/wcfsetup/install/files/acp/templates/userOptionAdd.tpl @@ -100,7 +100,7 @@
- {foreach from=$availableOptionTypes item=availableOptionType} {/foreach} diff --git a/wcfsetup/install/files/lib/acp/form/UserOptionEditForm.class.php b/wcfsetup/install/files/lib/acp/form/UserOptionEditForm.class.php index 2ed4699092..1c05d541b9 100644 --- a/wcfsetup/install/files/lib/acp/form/UserOptionEditForm.class.php +++ b/wcfsetup/install/files/lib/acp/form/UserOptionEditForm.class.php @@ -56,9 +56,7 @@ class UserOptionEditForm extends UserOptionAddForm { public function readFormParameters() { parent::readFormParameters(); - if ($this->userOption->optionName === 'aboutMe') { - $this->optionType = 'aboutMe'; - } + $this->optionType = $this->userOption->optionType; } /**