From c61a9ce06d97f1f9300640bdb18263bc99d2bf03 Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Mon, 24 Dec 2018 12:34:12 +0300 Subject: no need to setRead for anonymous --- src/main/java/com/juick/service/MessagesServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/juick/service/MessagesServiceImpl.java b/src/main/java/com/juick/service/MessagesServiceImpl.java index 9d9a809d..245ae783 100644 --- a/src/main/java/com/juick/service/MessagesServiceImpl.java +++ b/src/main/java/com/juick/service/MessagesServiceImpl.java @@ -967,7 +967,7 @@ public class MessagesServiceImpl extends BaseJdbcService implements MessagesServ "ORDER BY replies.reply_id ASC", new MapSqlParameterSource("mid", mid).addValue("uid", user.getUid()), new MessageMapper()); - if (replies.size() > 0) { + if (replies.size() > 0 && !user.isAnonymous()) { setRead(user, mid); } replies.forEach(i -> i.setEntities(MessageUtils.getEntities(i))); -- cgit v1.2.3