We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 609adf6 commit 1ae025eCopy full SHA for 1ae025e
src/manipulation.js
@@ -121,8 +121,12 @@ function cloneCopyEvent( src, dest ) {
121
}
122
123
function getAll( context, tag ) {
124
- var ret = context.getElementsByTagName ? context.getElementsByTagName( tag || "*" ) :
125
- context.querySelectorAll ? context.querySelectorAll( tag || "*" ) :
+ // Support: IE9-11+
+ // Use typeof to avoid zero-argument method invocation on host objects (#15151)
126
+ var ret = typeof context.getElementsByTagName !== "undefined" ?
127
+ context.getElementsByTagName( tag || "*" ) :
128
+ typeof context.querySelectorAll !== "undefined" ?
129
+ context.querySelectorAll( tag || "*" ) :
130
[];
131
132
return tag === undefined || tag && jQuery.nodeName( context, tag ) ?
0 commit comments