mirror of
https://github.com/bitwarden/desktop.git
synced 2024-11-08 09:32:07 +01:00
convert nodelist to array
This commit is contained in:
parent
171c9f324d
commit
0656e732fe
@ -551,8 +551,9 @@
|
||||
function getFormElements(theDoc, limit) {
|
||||
var els = [];
|
||||
try {
|
||||
els = theDoc.querySelectorAll('input:not([type="hidden"]):not([type="submit"]):not([type="reset"])' +
|
||||
var elsList = theDoc.querySelectorAll('input:not([type="hidden"]):not([type="submit"]):not([type="reset"])' +
|
||||
':not([type="button"]):not([type="image"]):not([type="file"]), select');
|
||||
els = Array.prototype.slice.call(elsList);
|
||||
} catch (e) { }
|
||||
|
||||
return limit && els.length > limit ? els.slice(0, limit) : els;
|
||||
|
Loading…
Reference in New Issue
Block a user