Skip to content

Commit

Permalink
Merge pull request #37342 from ZhenjaHorbach/selected-bank-account-is…
Browse files Browse the repository at this point in the history
…-not-checked-in-bank-account-selection-step

Fix bug with Selected bank account is not checked in bank account selection step
  • Loading branch information
puneetlath authored Feb 28, 2024
2 parents 4fcfbb0 + 8cf4670 commit fcf50e4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/components/RadioButtons.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,9 @@ type RadioButtonsProps = {
function RadioButtons({items, onPress, defaultCheckedValue = '', radioButtonStyle, errorText, onInputChange = () => {}, value}: RadioButtonsProps, ref: ForwardedRef<View>) {
const styles = useThemeStyles();
const [checkedValue, setCheckedValue] = useState(defaultCheckedValue);

useEffect(() => {
if (value === checkedValue) {
if (value === checkedValue || value === undefined) {
return;
}
setCheckedValue(value ?? '');
Expand Down

0 comments on commit fcf50e4

Please sign in to comment.