Removing error in Contact Filter panel.

This commit is contained in:
Kartik Sharma 2025-10-15 16:56:18 +05:30
parent b23518f796
commit cc2a82e3f0

View File

@ -44,13 +44,15 @@ const ContactFilterPanel = forwardRef(
useImperativeHandle(ref, () => ({
resetFieldValue: (name, value) => {
setTimeout(() => {
if (value !== undefined) {
setValue(name, value);
} else {
reset({ ...getValues(), [name]: defaultContactFilter[name] });
}
}, 0);
},
getValues, // optional: allows parent to read current form values
getValues,
}));
useEffect(() => {