wait for error send before exit

This commit is contained in:
2020-05-14 12:24:53 +02:00
parent a632d56a2f
commit 78f7eab33c

View File

@@ -24,7 +24,7 @@ const bondFetchProcess = async (url) => {
});
var t1 = await BondData.json();
} catch (e) {
tgBot.sendMessage(tgInfo.debugChat, `ERROR: fetching bonds:\n${e}`);
await tgBot.sendMessage(tgInfo.debugChat, `ERROR: fetching bonds:\n${e}`);
throw e;
}
for (let data in t1) {