mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-12-23 19:45:05 +01:00
Make getUserLevel() public
Signed-off-by: RMidhunSuresh <rmidhunsuresh@gmail.com>
This commit is contained in:
parent
ddb7a16fb8
commit
f7a6fbd901
@ -42,10 +42,10 @@ export class PowerLevels {
|
|||||||
if (this._membership !== "join") {
|
if (this._membership !== "join") {
|
||||||
return Number.MIN_SAFE_INTEGER;
|
return Number.MIN_SAFE_INTEGER;
|
||||||
}
|
}
|
||||||
return this._getUserLevel(this._ownUserId);
|
return this.getUserLevel(this._ownUserId);
|
||||||
}
|
}
|
||||||
|
|
||||||
_getUserLevel(userId) {
|
getUserLevel(userId) {
|
||||||
if (this._plEvent) {
|
if (this._plEvent) {
|
||||||
let userLevel = this._plEvent.content?.users?.[userId];
|
let userLevel = this._plEvent.content?.users?.[userId];
|
||||||
if (typeof userLevel !== "number") {
|
if (typeof userLevel !== "number") {
|
||||||
|
Loading…
Reference in New Issue
Block a user