UI/AutoSizeInput: Fixes issue where controlledValue being null caused crash (#94078)

This commit is contained in:
kay delaney
2024-10-01 16:02:26 +01:00
committed by GitHub
parent a9095b1dd1
commit 1b82595251
@@ -32,7 +32,7 @@ export const AutoSizeInput = React.forwardRef<HTMLInputElement, Props>((props, r
// Update internal state when controlled `value` prop changes
useEffect(() => {
if (controlledValue !== undefined) {
if (controlledValue) {
setValue(controlledValue);
}
}, [controlledValue]);