mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-04 17:07:49 +00:00
Ensure the _.isRegExp is correct for various builds.
Former-commit-id: 38cf57053b89b1011bbfbd0b6a9cd31e91589c31
This commit is contained in:
7
build.js
7
build.js
@@ -1924,6 +1924,13 @@
|
||||
source = source.replace(matchFunction(source, 'isPlainObject'), function(match) {
|
||||
return match.replace(/!getPrototypeOf[^:]+:\s*/, '');
|
||||
});
|
||||
|
||||
// replace `_.isRegExp`
|
||||
source = replaceFunction(source, 'isRegExp', [
|
||||
'function isRegExp(value) {',
|
||||
" return value ? (typeof value == 'object' && toString.call(value) == regexpClass) : false;",
|
||||
'}'
|
||||
].join('\n'));
|
||||
}
|
||||
}
|
||||
if (isMobile || isUnderscore) {
|
||||
|
||||
Reference in New Issue
Block a user