SAP-archive / yaas-nodejs-client-sdk

YaaS.js, a Node.js client library for SAP Hybris as a Service (YaaS)
Apache License 2.0
15 stars 5 forks source link

Adding HTTP HEAD support, and getCount to yaas-document.js #7

Closed blzjns closed 7 years ago

blzjns commented 7 years ago

Some services endpoints use the HEAD http method to return number of objects.

For example: /{tenant}/{client}/data/{type}

Line 199 in yaas-requesthelper.js changed to support responses without body: responseBody = response.body ? JSON.parse(response.body) : null;

abrain commented 7 years ago

Thanks for the contribution!

The test fails because of security restrictions by Travis CI. The environment variables are protected and will not be used for PRs from forks. I'll test locally and merge when the test succeeds.