check null in SlidingCaptchaSolver.js
This commit is contained in:
@@ -36,7 +36,9 @@ const PAGE_OPTIMIZATION_CHROME_FR_5 = "Avec la mesure des performance"
|
||||
const ONLINE_APPOINTMENT = "Online Appointment"
|
||||
const CONFIRM_RESEND_FORM_FR = "Confirmer le nouvel envoi"
|
||||
const CLOSED_MESSAGE_FR = "Depuis plus de 130 ans"
|
||||
const ABOUT_BLANK = " about:blank"
|
||||
const DIALOG_TO_SKIP = "facilement les commandes"
|
||||
const ABOUT_BLANK = "about:blank"
|
||||
const GOOGLE_DISCONNECT_FR = "Rester déconnecté"
|
||||
|
||||
async function convertImageToWhiteBlack(image_path) {
|
||||
const image = await Jimp.read(image_path);
|
||||
@@ -90,6 +92,10 @@ class OCRChecker {
|
||||
return OCRResult.CLOSED
|
||||
} else if (result.includes(ABOUT_BLANK)) {
|
||||
return OCRResult.TERMINAED
|
||||
} else if (result.includes(DIALOG_TO_SKIP)) {
|
||||
return OCRResult.TO_SKIP
|
||||
} else if (result.includes(GOOGLE_DISCONNECT_FR)) {
|
||||
return OCRResult.GOOGLE_DISCONNECT
|
||||
}
|
||||
} catch (e) {
|
||||
console.log(e)
|
||||
|
||||
Reference in New Issue
Block a user