nordnet-next-api
Advanced tools
Comparing version 4.1.0 to 4.1.1
@@ -213,2 +213,8 @@ 'use strict'; | ||
return { response: response, data: data, status: response.status }; | ||
}).catch(function (error) { | ||
return Promise.reject({ | ||
response: response, | ||
status: response.status, | ||
error: new Error('fetch unable to parse input, most likely API responded with empty reponse.\n Original Error: ' + error) | ||
}); | ||
}); | ||
@@ -215,0 +221,0 @@ } |
{ | ||
"name": "nordnet-next-api", | ||
"version": "4.1.0", | ||
"version": "4.1.1", | ||
"description": "Nordnet nExt API Javascript client", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -164,3 +164,10 @@ import es6Promise from 'es6-promise'; | ||
return response[method]().then(data => ({ response, data, status: response.status })); | ||
return response[method]() | ||
.then(data => ({ response, data, status: response.status })) | ||
.catch(error => Promise.reject({ | ||
response, | ||
status: response.status, | ||
error: new Error(`fetch unable to parse input, most likely API responded with empty reponse. | ||
Original Error: ${error}`), | ||
})); | ||
} | ||
@@ -167,0 +174,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
54436
1388