diff options
-rw-r--r-- | portal/ws/portal.ml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/portal/ws/portal.ml b/portal/ws/portal.ml index 33e5743..3b15fbc 100644 --- a/portal/ws/portal.ml +++ b/portal/ws/portal.ml @@ -68,9 +68,6 @@ let header ?from {domain; stream; push; _} = | Some id -> Lwt.return id | None -> Lwt.fail_with "Invalid stream opening server-side." -(** [close] is a [<close/>] stanza. *) -let close = {|<close xmlns="|} ^ xmlns ^ {|" />|} |> string |> parse_xml |> signals - (** [ws_endpoint domain] is a promise containing the XMPP websocket endpoint associated with [domain], by using the domain's Web-host Metadata. @@ -127,6 +124,9 @@ let connect (domain : domain) : socket Lwt.t = let+ () = wait is_open in {domain; stream; push} in ws_endpoint domain >>= ws_stream +(** [close] is a [<close/>] stanza. *) +let close = {|<close xmlns="|} ^ xmlns ^ {|" />|} |> string |> parse_xml |> signals + (** [portal_of_socket] is a Portal communicating with the socket [socket] via the Websocket subprotocol. |