SymphonyPlatformSolutions / symphony-api-client-node

Symphony API Client for NodeJS
MIT License
6 stars 20 forks source link

Request response - JSON.parse error #70

Closed binhnguyenfpt closed 4 years ago

binhnguyenfpt commented 4 years ago

Hi all. I 'm member in FPT, we are using this lib for develop some feature. I see a problem in this lib at file: https://github.com/SymphonyPlatformSolutions/symphony-api-client-node/blob/master/lib/Request/index.js

code wrong at:

 defer.resolve(str === '' ? {} : JSON.parse(str))

when str is HTML content for cases:

Please take a look. Thanks!

binhnguyenfpt commented 4 years ago

This bug is being tracked in Jira ticket: https://perzoinc.atlassian.net/browse/PLAT-8708

micaste commented 4 years ago

The fix has been released in version 1.1.0. Could you try if this fixes your issue @binhnguyenfpt ?