Skip to content

Commit

Permalink
fix: mint card and data load on minting
Browse files Browse the repository at this point in the history
  • Loading branch information
NMCarv committed Nov 30, 2022
1 parent fab47a8 commit f74238d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
7 changes: 1 addition & 6 deletions apps/website/components/molecules/mint-card/mint-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export const MintCard = ({ credential, sx, ...props }: MintCardProps) => {
);
const [error, setError] = useState<any | null>(null);

const { mintCredential: triggerMint, mintStatus } = useBiconomy();
const { mintCredential: triggerMint } = useBiconomy();

const mint = () => {
const trigger = triggerMint(credential);
Expand Down Expand Up @@ -62,11 +62,6 @@ export const MintCard = ({ credential, sx, ...props }: MintCardProps) => {
}
}, [credential.status]);

useEffect(() => {
mintStatus[credential.id]?.askingSignature &&
setMintProcessStatus(Subjects.sign);
}, [mintStatus[credential.id]]);

return (
<Card
sx={{
Expand Down
4 changes: 3 additions & 1 deletion apps/website/providers/biconomy/biconomy-provider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,10 @@ export function BiconomyProvider({ children }: ProviderProps) {
},
}));

console.log(id);

queryClient.invalidateQueries(['credentials']);
queryClient.invalidateQueries(['credential', id]);
queryClient.resetQueries(['credential', id]);

queryClient.resetQueries(['user_info', me?.id]);
},
Expand Down

0 comments on commit f74238d

Please sign in to comment.