mirror of
https://github.com/mgerb/mywebsite
synced 2026-01-12 02:42:48 +00:00
updated bunch of file paths and changed the way posts are loaded
This commit is contained in:
20
node_modules/regexp-clone/index.js
generated
vendored
Normal file
20
node_modules/regexp-clone/index.js
generated
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
|
||||
var toString = Object.prototype.toString;
|
||||
|
||||
function isRegExp (o) {
|
||||
return 'object' == typeof o
|
||||
&& '[object RegExp]' == toString.call(o);
|
||||
}
|
||||
|
||||
module.exports = exports = function (regexp) {
|
||||
if (!isRegExp(regexp)) {
|
||||
throw new TypeError('Not a RegExp');
|
||||
}
|
||||
|
||||
var flags = [];
|
||||
if (regexp.global) flags.push('g');
|
||||
if (regexp.multiline) flags.push('m');
|
||||
if (regexp.ignoreCase) flags.push('i');
|
||||
return new RegExp(regexp.source, flags.join(''));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user