From 425d0eb88c1b04e93bc32fcd900d8fcfa3a29410 Mon Sep 17 00:00:00 2001 From: Rory& Date: Tue, 15 Apr 2025 18:13:56 +0200 Subject: Fix session store --- MatrixUtils.Web/Pages/Index.razor | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'MatrixUtils.Web/Pages') diff --git a/MatrixUtils.Web/Pages/Index.razor b/MatrixUtils.Web/Pages/Index.razor index 7103dc5..7de4613 100644 --- a/MatrixUtils.Web/Pages/Index.razor +++ b/MatrixUtils.Web/Pages/Index.razor @@ -158,14 +158,14 @@ Small collection of tools to do not-so-everyday things. _currentSession = await sessionStore.GetCurrentSession(); _sessions.Clear(); _offlineSessions.Clear(); - var tokens = await sessionStore.GetAllSessions(); + var sessions = await sessionStore.GetAllSessions(); scannedSessions = 0; - totalSessions = tokens.Count; + totalSessions = sessions.Count; logger.LogDebug("Found {0} tokens", totalSessions); - if (tokens is not { Count: > 0 }) { + if (sessions is not { Count: > 0 }) { Console.WriteLine("No tokens found, trying migration from MRU..."); - tokens = await sessionStore.GetAllSessions(); - if (tokens is not { Count: > 0 }) { + sessions = await sessionStore.GetAllSessions(); + if (sessions is not { Count: > 0 }) { Console.WriteLine("No tokens found"); return; } @@ -174,7 +174,7 @@ Small collection of tools to do not-so-everyday things. List offlineServers = []; var sema = new SemaphoreSlim(8, 8); var updateSw = Stopwatch.StartNew(); - var tasks = tokens.Select(async session => { + var tasks = sessions.Select(async session => { await sema.WaitAsync(); var token = session.Value.Auth; -- cgit 1.5.1