Skip to content

Commit

Permalink
Define power levels to disable calls/reactions/redaction/stickers in PM
Browse files Browse the repository at this point in the history
No one but the sender can see them because we cannot bridge them.
Blocking them with PLs allows the clients to hide these features
from their UI, so users do not mistakenly believe they will be received.
  • Loading branch information
progval committed Feb 17, 2023
1 parent 646a9e5 commit 4faa978
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 2 deletions.
7 changes: 6 additions & 1 deletion spec/integ/pm.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -284,7 +284,12 @@ describe("IRC-to-Matrix PMing", () => {
"m.room.canonical_alias": 100,
"m.room.history_visibility": 100,
"m.room.power_levels": 100,
"m.room.encryption": 100
"m.room.encryption": 100,
"m.call.invite": 100,
"m.call.candidate": 100,
"m.reaction": 100,
"m.room.redaction": 100,
"m.sticker": 100,
},
invite: 100
},
Expand Down
10 changes: 9 additions & 1 deletion src/bridge/IrcHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,15 @@ export class IrcHandler {
"m.room.canonical_alias": 100,
"m.room.history_visibility": 100,
"m.room.power_levels": 100,
"m.room.encryption": 100
"m.room.encryption": 100,
// Event types that we cannot translate to IRC;
// we might as well block them with PLs so
// Matrix clients can hide them from their UI.
"m.call.invite": 100,
"m.call.candidate": 100,
"m.reaction": 100,
"m.room.redaction": 100,
"m.sticker": 100,
},
invite: 100,
},
Expand Down

0 comments on commit 4faa978

Please sign in to comment.