Skip to content

Commit

Permalink
Add "knock" join_rule to checkKnocking check
Browse files Browse the repository at this point in the history
  • Loading branch information
S7evinK committed Jan 15, 2024
1 parent 446521e commit e0911c0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion eventauth.go
Original file line number Diff line number Diff line change
Expand Up @@ -1236,7 +1236,7 @@ func disallowKnocking(m *membershipAllower) error {
}

func checkKnocking(m *membershipAllower) error {
supported := m.joinRule.JoinRule == spec.Restricted || m.joinRule.JoinRule == spec.KnockRestricted
supported := m.joinRule.JoinRule == spec.Knock || m.joinRule.JoinRule == spec.Restricted || m.joinRule.JoinRule == spec.KnockRestricted
if !supported {
return m.membershipFailed(
"room version %q does not support knocking on rooms with join rule %q",
Expand Down

0 comments on commit e0911c0

Please sign in to comment.