Fixed a regression when updating javascript stringify. Fixes #355.
This commit is contained in:
parent
d0698b1ffc
commit
edca6323fb
@ -18,7 +18,7 @@
|
||||
|
||||
String.prototype.slugify = function(sep) {
|
||||
if (typeof sep == 'undefined') sep = '_';
|
||||
var alphaNumRegexp = new RegExp('[^\w\\' + sep + ']', 'g');
|
||||
var alphaNumRegexp = new RegExp('[^\\w\\' + sep + ']', 'g');
|
||||
var avoidDuplicateRegexp = new RegExp('[\\' + sep + ']{2,}', 'g');
|
||||
return this.replace(/\s/g, sep).replace(alphaNumRegexp, '').replace(avoidDuplicateRegexp, sep).toLowerCase()
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user