* Merges #1879 from @laeleoni
* Fixes #1879
This commit is contained in:
Steve Gravrock
2022-01-15 11:36:56 -08:00
3 changed files with 111 additions and 22 deletions

View File

@@ -525,17 +525,16 @@ getJasmineRequireObj().MatchersUtil = function(j$) {
};
function keys(obj, isArray) {
var allKeys = Object.keys
? Object.keys(obj)
: (function(o) {
var keys = [];
for (var key in o) {
if (j$.util.has(o, key)) {
keys.push(key);
}
}
return keys;
})(obj);
var allKeys = (function(o) {
var keys = [];
for (var key in o) {
if (j$.util.has(o, key)) {
keys.push(key);
}
}
// eslint-disable-next-line compat/compat
return keys.concat(Object.getOwnPropertySymbols(o));
})(obj);
if (!isArray) {
return allKeys;