profile update

This commit is contained in:
YasinShaikh123
2024-08-23 18:02:50 +05:30
parent 5e4ebe3fb5
commit b8390bfad9

View File

@@ -36,11 +36,15 @@ const ProfileView = () => {
const id = params?.id;
const { data, isLoading, errors } = useGetInvestorsDetailsByIdQuery(id, {
const { data, isLoading, errors, refetch} = useGetInvestorsDetailsByIdQuery(id, {
skip: !id,
});
// Use useEffect to refetch data when the component mounts
useEffect(() => {
refetch();
}, [refetch]);
const foundObject = data?.data;