Fixed qu all breaking if no selectors are passed. Fixed old Kelly Madison scene URLs.
This commit is contained in:
@@ -142,6 +142,10 @@ function all(context, selectors, attrArg, applyTrim = true) {
|
||||
const attr = attrArg === true ? 'textContent' : attrArg;
|
||||
const elements = [].concat(selectors).reduce((acc, selector) => acc || getElements(context, selector), null);
|
||||
|
||||
if (!Array.isArray(elements)) {
|
||||
return [];
|
||||
}
|
||||
|
||||
if (attr) {
|
||||
return elements.map((el) => q(el, null, attr, applyTrim));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user