From 3f50065dedb6946de57280ffecec94f86e2ba3a1 Mon Sep 17 00:00:00 2001 From: Kiran Niranjan Date: Thu, 9 Nov 2017 19:09:52 +0530 Subject: [PATCH] Electron-206 - Added code comments --- js/dialogs/showBasicAuth.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/js/dialogs/showBasicAuth.js b/js/dialogs/showBasicAuth.js index 716dc5e8..d91cb105 100644 --- a/js/dialogs/showBasicAuth.js +++ b/js/dialogs/showBasicAuth.js @@ -14,7 +14,10 @@ electron.app.on('login', (event, webContents, request, authInfo, callback) => { event.preventDefault(); - if(currentAuthURL !== request.url) { + // This check is to determine whether the request is for the same + // host if so then increase the login tries from which we can + // display invalid credentials + if (currentAuthURL !== request.url) { currentAuthURL = request.url; } else { tries++