woovibr / php-sdk

OpenPix/Woovi PHP SDK
https://developers.openpix.com.br/docs/sdk/php/sdk-php-what-is
MIT License
11 stars 1 forks source link

Throw ApiErrorException with returned error array #29

Closed criskell closed 1 year ago

criskell commented 1 year ago

The API currently may return an object of type {error: string} or {error: { message: string }} (for example, when removing a charge that does not exist). This PR adds support for the last case, which was causing bugs in previous versions.