From 465e5571f8af340a3611290eba01c2b1d9fd22cd Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Mon, 29 Apr 2019 16:25:25 +0300 Subject: Fit netneladno.ru queries --- src/main/java/com/juick/service/MessagesServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/java/com/juick') diff --git a/src/main/java/com/juick/service/MessagesServiceImpl.java b/src/main/java/com/juick/service/MessagesServiceImpl.java index b1cb03d9..a1ba26ac 100644 --- a/src/main/java/com/juick/service/MessagesServiceImpl.java +++ b/src/main/java/com/juick/service/MessagesServiceImpl.java @@ -803,7 +803,7 @@ public class MessagesServiceImpl extends BaseJdbcService implements MessagesServ "SELECT message_id FROM " + "(SELECT message_id FROM favorites " + " INNER JOIN users" + - " ON messages.user_id = users.id" + + " ON favorites.user_id = users.id" + " WHERE user_id = :uid AND users.banned = 0" + (before > 0 ? " AND message_id < :before " : StringUtils.EMPTY) + -- cgit v1.2.3