I have a verification check function
async verifyWithOTP(phone: string, otp: string) {
console.log({ phone, otp });
try {
console.log("awaiting verification");
const verification = await client.verify.v2
.services("VA32f14036285fccdcc0a7ac76ac424515")
.verificationChecks.create({
to: phone,
code: otp,
});
console.log(verification.status);
console.log("verification successful");
return true;
} catch (error) {
console.log("failed to verify:", error);
return false;
}
}
This function is called in elysiajs which run in Bun runtime. But the promise never resolves, so the code just get stuck after printing "awaiting verification". As a result the function is of no use, but twilio dashboard shows approved for that request. So the client must be getting hanged. Is there any other solution or should I move to a node based backend framework?
it seems like the issue is on bun's side. I suggest to keep an eye on bun's github repo for the updates.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With