Open SolWinArg opened 4 years ago
Update Found bug on file 'woocommerce-rest-api/index.js' at the commented screen below..
It appears that the "replace" method is not working propperly...
Looks like this issue is related to https://github.com/woocommerce/woocommerce-rest-api-js-lib/ so moving it there.
Describe the bug When requesting data to the WooComerce REST API with params the generated link is wrongly created.
To Reproduce Make an api call with like this: WooCommerce.get("products", { per_page : 99, page: 1 })... // continues // Inside the callback... console.log(response) // "response" being the list of 99 products in page 1
The url generated is: http://example.com/wp-json/wc/v3/products?page=1&per_page=99&function%20()%7Breturn%20this.filter(a)%7D=undefined
The result of console.log(response) is "undefined"
Expected behavior There should be an object containing the 99 prods of page 1, among other important data.
I have