diff --git a/include/mls/state.h b/include/mls/state.h index 36a9409f..5f736bea 100644 --- a/include/mls/state.h +++ b/include/mls/state.h @@ -397,7 +397,7 @@ class State static bool valid_restart(const std::vector& proposals, ResumptionPSKUsage allowed_usage); - static bool valid_external_proposal_type(const Proposal::Type proposal_type); + static bool valid_external_proposal_type(const Proposal::Type proposal_type); CommitParams infer_commit_type( const std::optional& sender, diff --git a/src/state.cpp b/src/state.cpp index 48e5905e..44972eee 100644 --- a/src/state.cpp +++ b/src/state.cpp @@ -1251,8 +1251,8 @@ State::cache_proposal(AuthenticatedContent content_auth) const auto& proposal = var::get(content_auth.content.content); - if (content_auth.content.sender.sender_type() == SenderType::external - && !valid_external_proposal_type(proposal.proposal_type())) { + if (content_auth.content.sender.sender_type() == SenderType::external && + !valid_external_proposal_type(proposal.proposal_type())) { throw ProtocolError("Invalid external proposal"); } @@ -1875,7 +1875,8 @@ State::valid_restart(const std::vector& proposals, return acceptable_psks && found_allowed; } -bool State::valid_external_proposal_type(const Proposal::Type proposal_type) +bool +State::valid_external_proposal_type(const Proposal::Type proposal_type) { switch (proposal_type) { case ProposalType::add: