From 37db05a5574e2e75c919562c9bd95d0209625ac8 Mon Sep 17 00:00:00 2001 From: Kai Jan Kriegel Date: Sat, 12 Mar 2022 00:51:42 +0100 Subject: [PATCH] fix stupid logic error --- src/api/auth.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/auth.rs b/src/api/auth.rs index 8f260ba..85a7c8c 100644 --- a/src/api/auth.rs +++ b/src/api/auth.rs @@ -133,7 +133,7 @@ impl authentication_system::Server for Auth { // Extract the MECHANISM the client wants to use and start a session. // Or fail at that and thrown an exception TODO: return Outcome let mech = pry!(req.get_mechanism()); - if mech != "PLAIN" || mech != "X-FABFIRE" { + if !((mech == "PLAIN") || (mech == "X-FABFIRE")) { return Promise::err(capnp::Error { kind: capnp::ErrorKind::Failed, description: format!("Invalid SASL mech"),