summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2014-09-04 15:17:34 -0400
committerJames Moger <james.moger@gitblit.com>2014-09-04 15:17:34 -0400
commit5a4ac53238de477ff866b1f05b774ff714bcd71d (patch)
tree43a9f6e4cdbe838a623155570c87e5742adfa0f9
parent21fe98ebf8687f68cffbe6b6b8dec0073e93c541 (diff)
parenta4fa1b996be8641aa5c89375ee78cc6eb70a7c76 (diff)
downloadgitblit-5a4ac53238de477ff866b1f05b774ff714bcd71d.tar.gz
gitblit-5a4ac53238de477ff866b1f05b774ff714bcd71d.zip
Merge branch 'ticket/153' into develop
-rw-r--r--src/main/java/com/gitblit/tickets/TicketIndexer.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/main/java/com/gitblit/tickets/TicketIndexer.java b/src/main/java/com/gitblit/tickets/TicketIndexer.java
index 98fe6977..11ea3a73 100644
--- a/src/main/java/com/gitblit/tickets/TicketIndexer.java
+++ b/src/main/java/com/gitblit/tickets/TicketIndexer.java
@@ -143,8 +143,10 @@ public class TicketIndexer {
private String escape(String value) {
if (value.charAt(0) != '"') {
- if (value.indexOf('/') > -1 || value.indexOf('-') > -1) {
- return "\"" + value + "\"";
+ for (char c : value.toCharArray()) {
+ if (!Character.isLetterOrDigit(c)) {
+ return "\"" + value + "\"";
+ }
}
}
return value;