diff options
author | Vitaly Takmazov | 2018-09-11 09:49:48 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2018-09-11 09:49:48 +0300 |
commit | 4270d6b384b72491a7cc3440cc154049e9ad567e (patch) | |
tree | 553026305bca6cbd86988a7695f1e8ef5c76b7dd /juick-server/src/main/java/com/juick/server/api | |
parent | c7145b18652e9a4264910853133e7bf29559cdc5 (diff) |
XMPP: do not start when jid is not set
Diffstat (limited to 'juick-server/src/main/java/com/juick/server/api')
-rw-r--r-- | juick-server/src/main/java/com/juick/server/api/Index.java | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/juick-server/src/main/java/com/juick/server/api/Index.java b/juick-server/src/main/java/com/juick/server/api/Index.java index 0faf270f..947ac920 100644 --- a/juick-server/src/main/java/com/juick/server/api/Index.java +++ b/juick-server/src/main/java/com/juick/server/api/Index.java @@ -43,8 +43,6 @@ import java.util.stream.Collectors; public class Index { @Inject private WebsocketManager wsHandler; - @Inject - private XMPPServer xmpp; @RequestMapping(value = { "/api/", "/ws/" }, method = RequestMethod.GET, headers = "Connection!=Upgrade") public ResponseEntity<Void> description() { @@ -56,14 +54,4 @@ public class Index { public Status status() { return Status.getStatus(String.valueOf(wsHandler.getClients().size())); } - @RequestMapping(method = RequestMethod.GET, value = "/api/xmpp-status", produces = MediaType.APPLICATION_JSON_UTF8_VALUE) - public XMPPStatus xmppStatus() { - XMPPStatus status = new XMPPStatus(); - if (xmpp != null) { - status.setInbound(xmpp.getInConnections().stream().map(c -> c.from).flatMap(j -> j.stream().map(Jid::getDomain)).collect(Collectors.toList())); - status.setOutbound(xmpp.getOutConnections().keySet().stream() - .map(c -> c.to).map(Jid::getDomain).collect(Collectors.toList())); - } - return status; - } } |