From: Matthias Schmidt Date: Sat, 27 Jun 2020 05:51:02 +0000 (+0200) Subject: Fix checking current value of radio button form fields X-Git-Tag: 5.2.7~3 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=53f92bba9be098a94d796acc4d6986bed91bc8a8;p=GitHub%2FWoltLab%2FWCF.git Fix checking current value of radio button form fields --- diff --git a/com.woltlab.wcf/templates/__radioButtonFormField.tpl b/com.woltlab.wcf/templates/__radioButtonFormField.tpl index 6080d1d43d..8ca9eef8a6 100644 --- a/com.woltlab.wcf/templates/__radioButtonFormField.tpl +++ b/com.woltlab.wcf/templates/__radioButtonFormField.tpl @@ -4,7 +4,7 @@ *}type="radio" {* *}name="{@$field->getPrefixedId()}" {* *}value="{$__fieldValue}"{* - *}{if $field->getValue() === $__fieldValue} checked{/if}{* + *}{if $field->getValue() !== null && $field->getValue() == $__fieldValue} checked{/if}{* *}{if $field->isImmutable()} disabled{/if}{* *}> {@$__fieldLabel} diff --git a/wcfsetup/install/files/acp/templates/__radioButtonFormField.tpl b/wcfsetup/install/files/acp/templates/__radioButtonFormField.tpl index 6080d1d43d..8ca9eef8a6 100644 --- a/wcfsetup/install/files/acp/templates/__radioButtonFormField.tpl +++ b/wcfsetup/install/files/acp/templates/__radioButtonFormField.tpl @@ -4,7 +4,7 @@ *}type="radio" {* *}name="{@$field->getPrefixedId()}" {* *}value="{$__fieldValue}"{* - *}{if $field->getValue() === $__fieldValue} checked{/if}{* + *}{if $field->getValue() !== null && $field->getValue() == $__fieldValue} checked{/if}{* *}{if $field->isImmutable()} disabled{/if}{* *}> {@$__fieldLabel}