Don't cache powerlevel value

Co-authored-by: Bruno Windels <bruno@windels.cloud>
This commit is contained in:
R Midhun Suresh 2021-08-06 13:02:58 +05:30 committed by GitHub
parent 49be4e64ca
commit 974d9bf199
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -76,11 +76,7 @@ export class MemberDetailsViewModel extends ViewModel {
} }
get powerLevel() { get powerLevel() {
if (!this._powerLevel) { return this._powerLevelsObservable.get()?.getUserLevel(this._member.userId);
const powerLevels = this._powerLevelsObservable.get();
this._powerLevel = powerLevels.getUserLevel(this._member.userId);
}
return this._powerLevel;
} }
get linkToUser() { get linkToUser() {