Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Merge pull request #6517 from matrix-org/t3chguy/cp/6516
Browse files Browse the repository at this point in the history
[Release] createRoom, only send join rule event if we have a join rule to put in it
  • Loading branch information
t3chguy authored Jul 30, 2021
2 parents a7a84df + f86265b commit fe2993e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/createRoom.ts
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,8 @@ export default async function createRoom(opts: IOpts): Promise<string | null> {
}
}

if (opts.joinRule !== JoinRule.Restricted) {
// we handle the restricted join rule in the parentSpace handling block above
if (opts.joinRule && opts.joinRule !== JoinRule.Restricted) {
createOpts.initial_state.push({
type: EventType.RoomJoinRules,
content: { join_rule: opts.joinRule },
Expand Down

0 comments on commit fe2993e

Please sign in to comment.