Skip to content

Conversation

Cyclonecode
Copy link

@Cyclonecode Cyclonecode commented Jul 12, 2019

I was using this package for to handle oauth and making rest api requests to magento. In the filters to the endpoint I had a trailing & which made the request fail, so thought it would be a good idea to actually remove all empty parameters e.g

    const searchCriteria =
      'searchCriteria[filter_groups][0][filters][0][field]=entity_id&' +
      'searchCriteria[filter_groups][0][filters][0][value]=' + id + '&' +
      'searchCriteria[filter_groups][1][filters][0][field]=status&' +
      'searchCriteria[filter_groups][1][filters][0][value]=1&';

Here I really would like to remove the trailing &.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant