rest-client-sdk 6.7.1 → 6.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rest-client-sdk",
3
- "version": "6.7.1",
3
+ "version": "6.7.2",
4
4
  "description": "Rest Client SDK for API",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.es.js",
@@ -461,10 +461,13 @@ class AbstractClient<D extends MetadataDefinition> {
461
461
  requestParams: RequestInit
462
462
  ): Promise<Response> {
463
463
  let params = requestParams;
464
+ let baseHeaders: HeadersInit = {};
464
465
 
465
- const baseHeaders: HeadersInit = {
466
- 'Content-Type': 'application/json',
467
- };
466
+ if (params.method !== 'GET' || (params.method !== 'GET' && params.method !== 'DELETE')) {
467
+ baseHeaders = {
468
+ 'Content-Type': 'application/json',
469
+ };
470
+ }
468
471
 
469
472
  if (accessToken) {
470
473
  baseHeaders.Authorization = `${this.sdk.config.authorizationType} ${accessToken}`;