check EMPTY_RESPONSE_ERROR

This commit is contained in:
2022-10-07 12:45:17 +02:00
parent 957991c811
commit d5648b748a
+4
View File
@@ -25,6 +25,7 @@ const TIME_OUT = 60 * 1000 * 4//4 mins
const CONFIRMED_MESSAGE = "Your request for a Leather Goods appointment has been registered"
const CONFIRMED_MESSAGE_FR = "Votre demande de rendez-vous Maroquinerie a bien été enregistrée et nous vous en remercions."
const EMPTY_RESPONSE_ERROR = "ERR_EMPTY_RESPONSE"
const MESSAGE_URL_VALIDATION_FR = "Nous avons envoyé un lien par e-mail."
const MESSAGE_URL_VALIDATION_EN = "Please click on the link we sent by email"
const DOUBLE_REQUEST_ERROR_MESSAGE = "A request with the same data has already been validated today."
@@ -315,6 +316,9 @@ class CommandorPage {
if (content.includes(MESSAGE_URL_VALIDATION_FR) || content.includes(MESSAGE_URL_VALIDATION_EN)) {
log("successful");
await this.push_message_to_queue(PublishType.SUCCESS);
} else if (content.includes(EMPTY_RESPONSE_ERROR)) {
console.log("EMPTY_RESPONSE_ERROR error received, will quit")
this.isTerminated = true
} else {
// try to get errors
await this.getErrors()