diff options
author | Clombrong <cromblong@egregore.fun> | 2025-06-20 21:51:10 +0200 |
---|---|---|
committer | Clombrong <cromblong@egregore.fun> | 2025-06-24 10:35:29 +0200 |
commit | 1e2a9a742ed255399184589dc9cefd667038ec7d (patch) | |
tree | e4ca99c9d82a71f111c24acf03029f91fe92d944 | |
parent | bcfd9027ea438870cc8a48f132907fe5f43d55ef (diff) |
feat(stream): add parse_auth_mechanism function
-rw-r--r-- | lib/stream.ml | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/stream.ml b/lib/stream.ml index 1363352..6e4829b 100644 --- a/lib/stream.ml +++ b/lib/stream.ml @@ -8,6 +8,10 @@ type auth_mechanism = | PLAIN | Unknown of string [@@deriving show { with_path = false }] +let parse_auth_mechanism = function + | "PLAIN" -> PLAIN + | other -> Unknown other + let get (stream : (signal, async) stream) : (signal, sync) stream Lwt.t = (** [stanza stream] is a promise containing a full stanza of the fragments of [stream]. *) |