Skip to content

Commit

Permalink
Merge pull request #4738 from Giveth/feat_4724_givpower_so_buggy
Browse files Browse the repository at this point in the history
disabling caching from apolloClient to provide correct boost value fr…
  • Loading branch information
HrithikSampson authored Sep 23, 2024
2 parents 2e783de + 984ccbd commit 751a03a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/components/modals/Boost/BoostInnerModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@ const BoostInnerModal: FC<IInnerBoostModalProps> = ({
skip: 0,
userId: parseFloat(user.id || '') || -1,
},
fetchPolicy: 'no-cache',
});

setLoading(false);
Expand All @@ -186,7 +187,7 @@ const BoostInnerModal: FC<IInnerBoostModalProps> = ({
}
};
fetchUserBoosts();
}, [user]);
}, [user, isSaving]);

const confirmAllocation = async () => {
setIsSaving(true);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export const useFetchPowerBoostingInfo = (user: IUser) => {
orderBy: { field: order.by, direction: order.direction },
userId: parseFloat(user.id || '') || -1,
},
fetchPolicy: 'no-cache',
});
setTotalCount(data?.getPowerBoosting.totalCount || 0);
setLoading(false);
Expand Down

0 comments on commit 751a03a

Please sign in to comment.