forked from mystiq/hydrogen-web
don't expose joinRule prop, as it is protocol specific
This commit is contained in:
parent
86e8b27cb3
commit
fd454f1e20
1 changed files with 7 additions and 3 deletions
|
@ -68,8 +68,12 @@ export class Invite extends EventEmitter {
|
|||
return this._inviter;
|
||||
}
|
||||
|
||||
get joinRule() {
|
||||
return this._inviteData.joinRule;
|
||||
get isPublic() {
|
||||
return this._inviteData.joinRule === "public";
|
||||
}
|
||||
|
||||
get canonicalAlias() {
|
||||
return this._inviteData.canonicalAlias;
|
||||
}
|
||||
|
||||
async accept(log = null) {
|
||||
|
@ -276,7 +280,7 @@ export function tests() {
|
|||
invite.afterSync(changes);
|
||||
assert.equal(invite.name, "Invite example");
|
||||
assert.equal(invite.avatarUrl, roomAvatarUrl);
|
||||
assert.equal(invite.joinRule, "invite");
|
||||
assert.equal(invite.isPublic, false);
|
||||
assert.equal(invite.timestamp, 1001);
|
||||
assert.equal(invite.isEncrypted, false);
|
||||
assert.equal(invite.isDirectMessage, false);
|
||||
|
|
Loading…
Reference in a new issue