inakiabt / etsy-php

Etsy API wrapper for PHP
74 stars 59 forks source link

Validator fails if price is an integer for createListing method #17

Closed tudor2004 closed 7 years ago

tudor2004 commented 8 years ago

The data validator fails if the given price is an integer for createListing method. I think the validator should support an two-type check so that it can check against int and float at same time.

A quick, dirty fix would be to change the supported type from float to string in methods.json and always provide the price as a string.

inakiabt commented 7 years ago

Sorry for the late response! You can always use 'price' => 100.0. This library is just a wrapper of Etsy's API and if its documentation says price is float we should use that. Thanks