mirror of
https://github.com/louislam/uptime-kuma.git
synced 2024-11-27 16:54:04 +00:00
Minor
This commit is contained in:
parent
5cd506e340
commit
0eaaa8b6fa
1 changed files with 5 additions and 2 deletions
|
@ -25,8 +25,11 @@ class Telegram extends NotificationProvider {
|
||||||
return okMsg;
|
return okMsg;
|
||||||
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
let msg = (error.response && error.response.data && error.response.data.description) ? error.response.data.description : "Error without description";
|
if (error.response && error.response.data && error.response.data.description) {
|
||||||
throw new Error(msg);
|
throw new Error(error.response.data.description);
|
||||||
|
} else {
|
||||||
|
throw new Error(error.message);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue