Merge pull request #230 from plivo/timeout-remove-sms

fix: eliminate timeout for messaging
This commit is contained in:
Mohammed Huzaif 2021-12-08 10:44:31 +05:30 committed by GitHub
commit 72447ef98a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 10 additions and 5 deletions

View file

@ -1,5 +1,10 @@
# Change Log
## [v4.25.1](https://github.com/plivo/plivo-node/tree/v4.25.1) (2021-12-08)
**Bug Fix**
- Handling `undefined response` error from axios.
- Timeout has been eliminated for messaging requests.
## [v4.25.0](https://github.com/plivo/plivo-node/tree/v4.25.0) (2021-12-02)
**Features - Messaging: 10DLC API**
- 10DLC API's for brand and campaign support

View file

@ -96,7 +96,7 @@ export function Axios(config) {
.catch(function (error) {
//client side exception like file not found case
if (error.response == undefined){
reject(error.stack );
return reject(error.stack );
}
const exceptionClass = {
400: Exceptions.InvalidRequestError,
@ -175,7 +175,7 @@ export function Axios(config) {
if (typeof config.timeout !== 'undefined') {
options.timeout = config.timeout;
}
else if(typeof config.timeout === 'undefined'){
else if(typeof config.timeout === 'undefined' && isVoiceReq ){
options.timeout = 5000;
}
@ -212,7 +212,7 @@ export function Axios(config) {
})
.catch(function (error) {
if (error.response == undefined){
reject(error.stack );
return reject(error.stack );
}
const exceptionClass = {
400: Exceptions.InvalidRequestError,
@ -268,7 +268,7 @@ export function Axios(config) {
})
.catch(function (error) {
if (error.response == undefined){
reject(error.stack );
return reject(error.stack );
}
const exceptionClass = {
400: Exceptions.InvalidRequestError,

View file

@ -1,6 +1,6 @@
{
"name": "plivo",
"version": "4.25.0",
"version": "4.25.1",
"description": "A Node.js SDK to make voice calls and send SMS using Plivo and to generate Plivo XML",
"homepage": "https://github.com/plivo/plivo-node",
"files": [