ScaleLeap / amazon-mws-api-sdk

A fully typed TypeScript and Node.js Amazon MWS API Unofficial SDK
https://npm.im/@scaleleap/amazon-mws-api-sdk
MIT License
20 stars 12 forks source link

fix(offer_count): type obj to array #376

Closed Roman991 closed 3 years ago

Roman991 commented 3 years ago

Care, I dont know that ensureArray so before merging check if its coherent with the error

ParsingError: Problem with the value of property `GetLowestPricedOffersForASINResponse`: 
Problem with the value of property `GetLowestPricedOffersForASINResult`: 
Problem with the value of property `Summary`: 
Problem with the value of property `NumberOfOffers`: 
One of the following problems occured: (0) 
Problem with the value of property "OfferCount": 
One of the following problems occured: (0) 
Expected a number, but received an array with value 
[{
  "text":58,
  "attr":{"condition":"used","fulfillmentChannel":"Merchant"}
},
{
  "text":1,
  "attr":{"condition":"new","fulfillmentChannel":"Amazon"}
},
{
  "text":6,
  "attr":{"condition":"new","fulfillmentChannel":"Merchant"}
}], 
(1) Expected an object, but received an array with value 
[{...}], 
(1) Expected an undefined, but received an object with value {"OfferCount":[{"text":58,"attr":{"condition":"used","fulfillmentChannel":"Merchant"}},{"text":1,"attr":{"condition":"new","fulfillmentChannel":"Amazon"}},{"text":6,"attr":{"condition":"new","fulfillmentChannel":"Merchant"}}]
github-actions[bot] commented 3 years ago

:tada: This PR is included in version 1.9.52 :tada:

The release is available on:

Your semantic-release bot :package::rocket: