mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-17 22:57:21 +01:00
Disable Failing Webhooks (#11966)
* todo comment * add failures field to webhooks and sanitize * implement logic * use update instead of save * specify timeout and maximum number of retries * add tests
This commit is contained in:
@@ -131,6 +131,8 @@ export async function sendTxn (mailingInfoArray, emailType, variables, personalV
|
||||
|
||||
if (IS_PROD && mailingInfoArray.length > 0) {
|
||||
return got.post(`${EMAIL_SERVER.url}/job`, {
|
||||
retry: 5, // retry the http request to the email server 5 times
|
||||
timeout: 60000, // wait up to 60s before timing out
|
||||
auth: `${EMAIL_SERVER.auth.user}:${EMAIL_SERVER.auth.password}`,
|
||||
json: true,
|
||||
body: {
|
||||
|
||||
Reference in New Issue
Block a user