Merge pull request #28 from 002Hub/deepsource-fix-d37f38b5

Replace builtin prototype method with `Object.prototype` equivalent
This commit is contained in:
Code002Lover 2022-09-05 09:40:13 -07:00 committed by GitHub
commit 35f9492dbf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -398,7 +398,7 @@ function removeDuplicates(a) {
return a.filter(function(item) { return a.filter(function(item) {
let type = typeof item; let type = typeof item;
if(type in prims) if(type in prims)
return prims[type].hasOwnProperty(item) ? false : (prims[type][item] = true); return Object.prototype.hasOwnProperty.call(prims.type, item) ? false : (prims[type][item] = true);
else else
return objs.indexOf(item) >= 0 ? false : objs.push(item); return objs.indexOf(item) >= 0 ? false : objs.push(item);
}); });