diff options
author | Vitaly Takmazov | 2018-04-05 14:03:09 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2018-04-05 14:03:09 +0300 |
commit | 534d3c6f8ab31c0d41e6a6980f8cbc3f25e8d1b9 (patch) | |
tree | 9da4ecad27afa9750a6c0369e181e287944473bf /juick-server/src/main/java/com/juick/server/WebsocketManager.java | |
parent | 2f53f75e584e0522c8f4783bc28df4ad6eb3033d (diff) |
server: commands are not depended on xmpp now
Diffstat (limited to 'juick-server/src/main/java/com/juick/server/WebsocketManager.java')
-rw-r--r-- | juick-server/src/main/java/com/juick/server/WebsocketManager.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/juick-server/src/main/java/com/juick/server/WebsocketManager.java b/juick-server/src/main/java/com/juick/server/WebsocketManager.java index fc7035ab..8475fd40 100644 --- a/juick-server/src/main/java/com/juick/server/WebsocketManager.java +++ b/juick-server/src/main/java/com/juick/server/WebsocketManager.java @@ -70,7 +70,7 @@ public class WebsocketManager extends TextWebSocketHandler { @Inject private ObjectMapper jsonMapper; @Inject - private XMPPConnection xmppConnection; + private CommandsManager commandsManager; @Override @@ -151,7 +151,7 @@ public class WebsocketManager extends TextWebSocketHandler { Message draft = jsonMapper.readValue(message.asBytes(), Message.class); if (draft.getUser() != null && (draft.getText() != null || draft.getAttachment() != null)) { String attachmentFileName = draft.getAttachment() == null ? "" : draft.getAttachment().getUrl(); - xmppConnection.incomingMessageJuick(draft.getUser(), null, draft.getText(), URI.create(attachmentFileName)); + commandsManager.processCommand(draft.getUser(), null, draft.getText(), URI.create(attachmentFileName)); } } catch (Exception e) { throw new HttpBadRequestException(); |