Skip to content

Commit

Permalink
fix(subscriptions): 18998 update POST /billing_subscription to use js…
Browse files Browse the repository at this point in the history
…on body parameters (#789)
  • Loading branch information
albaranau authored Jul 11, 2024
1 parent 707dd7d commit 36b6c4f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/core/api/subscription.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,10 @@ export async function setCurrentUserSubscription(
billingPlanId: string,
billingSubscriptionId: string,
) {
// TODO: #18998 needs to use application/json, not search parameters! Requires BE changes to the endpoint first
const appId = configRepo.get().id;
return await apiClient.post<CurrentSubscription | null>(
`/users/current_user/billing_subscription?appId=${appId}&billingPlanId=${billingPlanId}&billingSubscriptionId=${billingSubscriptionId}`,
undefined,
`/users/current_user/billing_subscription`,
{ appId, billingPlanId, billingSubscriptionId },
true,
);
}

0 comments on commit 36b6c4f

Please sign in to comment.