diff options
author | Vitaly Takmazov | 2018-10-09 14:29:47 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2018-10-09 14:29:47 +0300 |
commit | 3bbaae4589de56da9ab09360aa28a3cd12198471 (patch) | |
tree | 436fd6436e582d0de7cbb0b3373e3d2d9fcc97ee /juick-server/src/main/java/com/juick/server/api | |
parent | 9eb0139ed6a0e823a0863c8734278e620587627f (diff) |
MessageReadEvent refactoring
Diffstat (limited to 'juick-server/src/main/java/com/juick/server/api')
-rw-r--r-- | juick-server/src/main/java/com/juick/server/api/Messages.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/juick-server/src/main/java/com/juick/server/api/Messages.java b/juick-server/src/main/java/com/juick/server/api/Messages.java index 6baa154b..424ea492 100644 --- a/juick-server/src/main/java/com/juick/server/api/Messages.java +++ b/juick-server/src/main/java/com/juick/server/api/Messages.java @@ -175,7 +175,7 @@ public class Messages { List<com.juick.Message> replies = messagesService.getReplies(visitor, mid); if (!visitor.isAnonymous()) { applicationEventPublisher.publishEvent( - new MessageReadEvent(this, Collections.singletonList(visitor), msg)); + new MessageReadEvent(this, visitor, msg)); } replies.add(0, msg); return ResponseEntity.ok(replies); @@ -190,7 +190,7 @@ public class Messages { messagesService.setLastReadComment(visitor, mid, rid); Message msg = messagesService.getMessage(mid); applicationEventPublisher.publishEvent( - new MessageReadEvent(this, Collections.singletonList(visitor), msg)); + new MessageReadEvent(this, visitor, msg)); return IOUtils.toByteArray( Objects.requireNonNull(getClass().getClassLoader().getResource("Transparent.gif"))); } |