Always allow call.member events on new rooms (#11948)

* Always allow call.member events on new rooms
This translate to: allow group calls by default

Signed-off-by: Timo K <toger5@hotmail.de>

* fix tests

Signed-off-by: Timo K <toger5@hotmail.de>

---------

Signed-off-by: Timo K <toger5@hotmail.de>
This commit is contained in:
Timo 2023-11-28 13:13:31 +01:00 committed by GitHub
parent fbf72f6a3a
commit 372737d075
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -187,9 +187,9 @@ export default async function createRoom(client: MatrixClient, opts: IOpts): Pro
createOpts.power_level_content_override = { createOpts.power_level_content_override = {
events: { events: {
...DEFAULT_EVENT_POWER_LEVELS, ...DEFAULT_EVENT_POWER_LEVELS,
// Element Call should be disabled by default // It should always (including non video rooms) be possible to join a group call.
[ElementCall.MEMBER_EVENT_TYPE.name]: 100, [ElementCall.MEMBER_EVENT_TYPE.name]: 0,
// Make sure only admins can enable it // Make sure only admins can enable it (DEPRECATED)
[ElementCall.CALL_EVENT_TYPE.name]: 100, [ElementCall.CALL_EVENT_TYPE.name]: 100,
}, },
}; };

View File

@ -127,7 +127,7 @@ describe("createRoom", () => {
]; ];
expect(callPower).toBe(100); expect(callPower).toBe(100);
expect(callMemberPower).toBe(100); expect(callMemberPower).toBe(0);
}); });
it("should upload avatar if one is passed", async () => { it("should upload avatar if one is passed", async () => {