Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/utils/lib/regexp.js
diff options
context:
space:
mode:
Diffstat (limited to 'utils/lib/regexp.js')
-rwxr-xr-xutils/lib/regexp.js12
1 files changed, 0 insertions, 12 deletions
diff --git a/utils/lib/regexp.js b/utils/lib/regexp.js
deleted file mode 100755
index f9dca58..0000000
--- a/utils/lib/regexp.js
+++ /dev/null
@@ -1,12 +0,0 @@
-// RegExp
-
-/*** RegExp.escape
- accepts a string; returns the string with regex metacharacters escaped.
- the returned string can safely be used within a regex to match a literal
- string. escaped characters are [, ], {, }, (, ), -, *, +, ?, ., \, ^, $,
- |, #, [comma], and whitespace.
-*/
-RegExp.escape = function (str) {
- return str.replace(/[-[\]{}()*+?.\\^$|,#\s]/g, "\\$&");
-};
-