From 6c5ad30c7903930209c293a2ce6dc15507ee3a44 Mon Sep 17 00:00:00 2001 From: Jeff Williams Date: Tue, 10 Jul 2012 06:09:11 -0700 Subject: [PATCH] disable JSHint's "regexdash" relaxing option --- .jshintrc | 2 +- rhino_modules/jsdoc/util/templateHelper.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.jshintrc b/.jshintrc index f91e6f72..4021e2cf 100644 --- a/.jshintrc +++ b/.jshintrc @@ -32,8 +32,8 @@ "loopfunc": true, "multistr": false, "onecase": true, - "regexdash": true, "proto": false, + "regexdash": false, "scripturl": true, "shadow": true, "smarttabs": true, diff --git a/rhino_modules/jsdoc/util/templateHelper.js b/rhino_modules/jsdoc/util/templateHelper.js index 0a1447f6..fe5e3106 100644 --- a/rhino_modules/jsdoc/util/templateHelper.js +++ b/rhino_modules/jsdoc/util/templateHelper.js @@ -46,7 +46,7 @@ function strToFilename(str) { // allow for namespace prefix var basename = str.replace(nsprefix, '$1-'); - if ( /[^$a-z0-9._-]/i.test(basename) ) { + if ( /[^$a-z0-9._\-]/i.test(basename) ) { return hash.hex_md5(str).substr(0, 10); } return makeFilenameUnique(basename, str);