Skip to content

Commit

Permalink
Fix push card api request (#271)
Browse files Browse the repository at this point in the history
  • Loading branch information
memeToasty authored Mar 6, 2024
1 parent e4e4a98 commit e82998d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frontend/util/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ export async function modifyCard(card: CardType) {
export async function pushCard(deckID: string, cardID: string, rating: number) {
const response = await postRequest(
pushCardsRoute(deckID),
JSON.stringify({ body: { cardID, rating } })
JSON.stringify({ cardID, rating })
);
if (response?.ok) mutateAll(cardRoutes(deckID));
return response;
Expand Down

0 comments on commit e82998d

Please sign in to comment.