Added !when command
This commit is contained in:
parent
6947fb843e
commit
4151ab95f8
6 changed files with 159 additions and 6 deletions
8
helpers/strings.js
Normal file
8
helpers/strings.js
Normal file
|
@ -0,0 +1,8 @@
|
|||
module.exports = {
|
||||
formatString: function (string) {
|
||||
if (string !== undefined && string !== null) {
|
||||
return new RegExp('^' + string.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&') + '$', 'i')
|
||||
}
|
||||
return ';'
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue