fix: add timeout to request

* incase the ussd-server is down or unresponsive, return a message to tg
This commit is contained in:
Mohamed Sohail 2022-01-18 14:50:20 +03:00
parent 05e441f6a1
commit f61500f3e6
Signed by: kamikazechaser
GPG Key ID: 7DD45520C01CD85D

View File

@ -8,6 +8,7 @@ async function proxy(sessionId, phone, input = "") {
url: config.get("USSD_ENDPOINT"),
method: "POST",
parse: "string",
timeout: 3000,
form: {
sessionId: sessionId,
phoneNumber: phone,