Bug 1596413 - after confirmation to follow possible scam link, use the right actions for yes/no. r+a=jorgk
--- a/mail/base/content/phishingDetector.js
+++ b/mail/base/content/phishingDetector.js
@@ -293,23 +293,24 @@ var gPhishingDetector = {
let dialogMsg = bundle.getFormattedString(
"confirmPhishingUrl",
[brandShortName, unobscuredHostNameValue],
2
);
let warningButtons =
Ci.nsIPromptService.STD_YES_NO_BUTTONS +
Ci.nsIPromptService.BUTTON_POS_1_DEFAULT;
- return Services.prompt.confirmEx(
+ let button = Services.prompt.confirmEx(
window,
titleMsg,
dialogMsg,
warningButtons,
"",
"",
"",
"",
{}
);
+ return button == 0 ? 2 : 1; // 2 == allow, 1 == block
}
return 2; // allow the link to load
},
};