MSG91 / sendotp-node

38 stars 24 forks source link

Uncaught exception for retryVoice = true #14

Open amitbravo opened 7 years ago

amitbravo commented 7 years ago

if I use retryVoice = true , it does not work , fail with "Uncaught exception" however working perfectly with false

sendOtp.retry(phone, false, function (error, data, res) { if(data.type == 'success'){ console.log('resent successfully'); admin.database().ref('/users/' + phone) .update({ code: code, codeValid: true }, () => { response.send({ success: true }); }); } else { return response.status(422).send(err); } });