Skip to content

Commit

Permalink
fix: remove JSON.stringify from sales.addProduct
Browse files Browse the repository at this point in the history
  • Loading branch information
alcaprar committed Aug 3, 2024
1 parent 3d124d8 commit ea39803
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions frontend/plugins/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -626,11 +626,11 @@ class SalesClient {
logger.debug(`[ApiClient][Sales][addProduct] saleId ${saleId} productId ${productId}`)
const url = `${this.baseUrl}/sales/${saleId}/products`;
try {
let body = JSON.stringify({
let body = {
data: {
productId: productId
},
});
};
logger.debug("[ApiClient][Sales][addProduct] body", body)
let response = await fetchAuthenticated('POST', url, body);
if (response.status == 404) {
Expand Down

0 comments on commit ea39803

Please sign in to comment.