You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
244 B
JavaScript
12 lines
244 B
JavaScript
7 years ago
|
var MATCH = require('./_wks')('match');
|
||
|
module.exports = function(KEY){
|
||
|
var re = /./;
|
||
|
try {
|
||
|
'/./'[KEY](re);
|
||
|
} catch(e){
|
||
|
try {
|
||
|
re[MATCH] = false;
|
||
|
return !'/./'[KEY](re);
|
||
|
} catch(f){ /* empty */ }
|
||
|
} return true;
|
||
|
};
|