From 3513bc640ae7a0e07245c4789623fa9457d4b403 Mon Sep 17 00:00:00 2001 From: Alexander Alexeev Date: Fri, 9 Dec 2016 23:04:20 +0700 Subject: bugfix: wrong sql parameter --- juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'juick-server/src/main') diff --git a/juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java b/juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java index aa3e454f..d7c1d51b 100644 --- a/juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java +++ b/juick-server/src/main/java/com/juick/service/MessagesServiceImpl.java @@ -482,7 +482,7 @@ public class MessagesServiceImpl extends BaseJdbcService implements MessagesServ return getNamedParameterJdbcTemplate().queryForList( "SELECT message_id FROM subscr_messages WHERE suser_id = :uid" + (before > 0 ? - " AND message_id < :before " : "") + + " AND message_id < :before " : " ") + "ORDER BY message_id DESC LIMIT 20", sqlParameterSource, Integer.class); -- cgit v1.2.3