aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/com/juick/www
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2020-10-20 23:43:41 +0300
committerGravatar Vitaly Takmazov2020-10-20 23:43:41 +0300
commitddfaa389a00fc198a35f8d505b24d9eb50ff75a5 (patch)
treec8d6efef9d4e984d6f85c912d85d8f5e85c3326d /src/main/java/com/juick/www
parent7feb5789d1eedd9e3b0ec88c5a8209e116e2b28e (diff)
Revert "Append * to keyword search"
This reverts commit 85c5c69ffb5a14258eafb4c67c550f6018b3c621.
Diffstat (limited to 'src/main/java/com/juick/www')
-rw-r--r--src/main/java/com/juick/www/api/Messages.java4
-rw-r--r--src/main/java/com/juick/www/controllers/Site.java8
2 files changed, 4 insertions, 8 deletions
diff --git a/src/main/java/com/juick/www/api/Messages.java b/src/main/java/com/juick/www/api/Messages.java
index a4d1eba8..b7e9cb0b 100644
--- a/src/main/java/com/juick/www/api/Messages.java
+++ b/src/main/java/com/juick/www/api/Messages.java
@@ -119,7 +119,7 @@ public class Messages {
} else if (daysback > 0) {
mids = messagesService.getUserBlogAtDay(user.getUid(), 0, daysback);
} else if (!StringUtils.isEmpty(search)) {
- mids = messagesService.getUserSearch(visitor, user.getUid(), WebUtils.encodeSphinx(search), 0, page, false);
+ mids = messagesService.getUserSearch(visitor, user.getUid(), WebUtils.encodeSphinx(search), 0, page);
} else {
mids = messagesService.getUserBlog(user.getUid(), 0, before);
}
@@ -139,7 +139,7 @@ public class Messages {
return NOT_FOUND;
}
} else if (!StringUtils.isEmpty(search)) {
- mids = messagesService.getSearch(visitor, WebUtils.encodeSphinx(search), page, false);
+ mids = messagesService.getSearch(visitor, WebUtils.encodeSphinx(search), page);
} else {
mids = messagesService.getAll(visitor.getUid(), before);
}
diff --git a/src/main/java/com/juick/www/controllers/Site.java b/src/main/java/com/juick/www/controllers/Site.java
index 59a3ed1d..dc037073 100644
--- a/src/main/java/com/juick/www/controllers/Site.java
+++ b/src/main/java/com/juick/www/controllers/Site.java
@@ -108,7 +108,7 @@ public class Site {
if (paramSearch != null) {
title = "Поиск: " + StringEscapeUtils.escapeHtml4(paramSearch);
- mids = messagesService.getSearch(visitor, WebUtils.encodeSphinx(paramSearch), page, false);
+ mids = messagesService.getSearch(visitor, WebUtils.encodeSphinx(paramSearch), page);
} else if (paramShow == null) {
title = "Обсуждения";
mids = messagesService.getDiscussions(visitor.getUid(), paramTo);
@@ -194,11 +194,8 @@ public class Site {
List<Integer> mids;
- boolean isTagSearch = false;
-
if (paramTagStr != null) {
paramSearch = paramTagStr;
- isTagSearch = true;
}
if (paramSearch != null && paramSearch.length() > 64) {
paramSearch = null;
@@ -217,8 +214,7 @@ public class Site {
if (paramShow == null) {
if (paramSearch != null) {
title = "Блог " + user.getName() + ": " + StringEscapeUtils.escapeHtml4(paramSearch);
- mids = messagesService.getUserSearch(visitor, user.getUid(), WebUtils.encodeSphinx(paramSearch),
- privacy, page, isTagSearch);
+ mids = messagesService.getUserSearch(visitor, user.getUid(), WebUtils.encodeSphinx(paramSearch), privacy, page);
} else {
title = "Блог " + user.getName();
mids = messagesService.getUserBlog(user.getUid(), privacy, before);