diff options
author | Clombrong <cromblong@egregore.fun> | 2025-06-11 00:07:05 +0200 |
---|---|---|
committer | Clombrong <cromblong@egregore.fun> | 2025-06-11 00:07:05 +0200 |
commit | f78267a4bb0e78d964d0c9fff63931600d82d5f1 (patch) | |
tree | dbca19eb850973a417c502b25ba2fd75e0c1946f /test/js | |
parent | 598d0321d74089f8f2717ce4f6cd3d9b19c44198 (diff) |
feat(auth): parse auth response and return appropriate result
Diffstat (limited to 'test/js')
-rw-r--r-- | test/js/websockets_hello.ml | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/test/js/websockets_hello.ml b/test/js/websockets_hello.ml index 8af5a5e..9043501 100644 --- a/test/js/websockets_hello.ml +++ b/test/js/websockets_hello.ml @@ -21,7 +21,10 @@ let main (stream, push) = in let+ _auth = Auth.send_auth_stanza (stream, push) "test@example.com" "password" Auth.PLAIN - in push None + in push None; + match _auth with + | Error (NotAuthorized, Some ("en", text)) -> print_endline text + | _ -> () let () = run @@ |