Skip to content

Commit c7e2f7e

Browse files
author
Marta Mularczyk
committed
fix: Validate version correctly (aka add missing parentheses)
1 parent 567e806 commit c7e2f7e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

mls-rs/src/client.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -761,7 +761,10 @@ where
761761
) -> Result<MlsMessage, MlsError> {
762762
let protocol_version = group_info.version;
763763

764-
if !self.config.version_supported(protocol_version) && protocol_version == self.version {
764+
let protocol_version_ok =
765+
self.config.version_supported(protocol_version) && protocol_version == self.version;
766+
767+
if !protocol_version_ok {
765768
return Err(MlsError::UnsupportedProtocolVersion(protocol_version));
766769
}
767770

0 commit comments

Comments
 (0)