about summary refs log tree commit diff
path: root/MatrixRoomUtils.Web/Shared/InlineUserItem.razor
diff options
context:
space:
mode:
authorTheArcaneBrony <[email protected]>2023-07-17 00:21:24 +0200
committerTheArcaneBrony <[email protected]>2023-07-17 00:21:24 +0200
commit1beca653b772cf10586c417b2c25df03a67df8a2 (patch)
treed539b5f329cb62f253e1bc8142c3a313719657b0 /MatrixRoomUtils.Web/Shared/InlineUserItem.razor
parentChanges (diff)
downloadMatrixUtils-1beca653b772cf10586c417b2c25df03a67df8a2.tar.xz
Handle external logouts
Diffstat (limited to 'MatrixRoomUtils.Web/Shared/InlineUserItem.razor')
-rw-r--r--MatrixRoomUtils.Web/Shared/InlineUserItem.razor9
1 files changed, 5 insertions, 4 deletions
diff --git a/MatrixRoomUtils.Web/Shared/InlineUserItem.razor b/MatrixRoomUtils.Web/Shared/InlineUserItem.razor

index ffccc25..f9cef91 100644 --- a/MatrixRoomUtils.Web/Shared/InlineUserItem.razor +++ b/MatrixRoomUtils.Web/Shared/InlineUserItem.razor
@@ -35,14 +35,15 @@ protected override async Task OnInitializedAsync() { await base.OnInitializedAsync(); - var hs = await MRUStorage.GetCurrentSession(); - + var hs = await MRUStorage.GetCurrentSessionOrNavigate(); + if(hs is null) return; + await _semaphoreSlim.WaitAsync(); if (User == null && UserId == null) throw new ArgumentNullException(nameof(UserId)); User ??= await hs.GetProfile(UserId); - + ProfileAvatar ??= MediaResolver.ResolveMediaUri(hs.FullHomeServerDomain, User.AvatarUrl); ProfileName ??= User.DisplayName; @@ -50,4 +51,4 @@ _semaphoreSlim.Release(); } -} \ No newline at end of file +}
OSZAR »