1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-18 17:23:37 +00:00

Remove empty catch blocks and remove allow-empty-catch tslint rule (#2136)

This commit is contained in:
Oscar Hinton
2021-10-21 11:10:46 +02:00
committed by GitHub
parent 6a02487778
commit ce2e6c3cb4
28 changed files with 103 additions and 67 deletions

View File

@@ -259,7 +259,9 @@ document.addEventListener('DOMContentLoaded', event => {
if (fieldData.htmlID != null && fieldData.htmlID !== '') {
try {
el = form.querySelector('#' + fieldData.htmlID);
} catch { }
} catch {
// Ignore error, we perform fallbacks below.
}
}
if (el == null && fieldData.htmlName != null && fieldData.htmlName !== '') {
el = form.querySelector('input[name="' + fieldData.htmlName + '"]');