mirror of
https://github.com/keepassxreboot/keepassxc-browser.git
synced 2026-03-11 08:54:43 +00:00
Fix TOTP field maxLength comparison
This commit is contained in:
parent
1af105b6eb
commit
bab175af04
2 changed files with 5 additions and 2 deletions
|
|
@ -34,7 +34,7 @@ TOTPFieldIcon.prototype.initField = function(field) {
|
|||
|| field.getAttribute('kpxc-totp-field') === 'true'
|
||||
|| field.offsetWidth < MINIMUM_SIZE
|
||||
|| field.size < 2
|
||||
|| (field.maxLength > 0 && field.maxLength < 4)
|
||||
|| (field.maxLength > 0 && (field.maxLength < 6 || field.maxLength > 8))
|
||||
|| field.id.match(ignoreRegex)
|
||||
|| field.name.match(ignoreRegex)) {
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -41,7 +41,10 @@ class UsernameFieldIcon extends Icon {
|
|||
}
|
||||
|
||||
UsernameFieldIcon.prototype.initField = function(field) {
|
||||
if (!field || field.getAttribute('kpxc-username-field') === 'true' || !kpxcFields.isVisible(field)) {
|
||||
if (!field
|
||||
|| field.getAttribute('kpxc-username-field') === 'true'
|
||||
|| field.getAttribute('kpxc-totp-field') === 'true'
|
||||
|| !kpxcFields.isVisible(field)) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue