node_modules/es-abstract/2022/IsRegExp.js in immosquare-cleaner-0.1.60 vs node_modules/es-abstract/2022/IsRegExp.js in immosquare-cleaner-0.1.61

- old
+ new

@@ -6,13 +6,15 @@ var hasRegExpMatcher = require('is-regex'); var ToBoolean = require('./ToBoolean'); +var isObject = require('../helpers/isObject'); + // https://262.ecma-international.org/6.0/#sec-isregexp module.exports = function IsRegExp(argument) { - if (!argument || typeof argument !== 'object') { + if (!isObject(argument)) { return false; } if ($match) { var isRegExp = argument[$match]; if (typeof isRegExp !== 'undefined') {