cleaned code

This commit is contained in:
2026-03-07 17:51:02 +01:00
parent 49aed2493a
commit 0e6caa136e
13 changed files with 39 additions and 33 deletions

View File

@@ -14,7 +14,7 @@ public class WhiteboardManager
_scopeFactory = scopeFactory;
}
public async Task AddWhiteboard(Guid whiteboardId)
public async Task LoadWhiteboard(Guid whiteboardId)
{
var getWhiteboardService = _scopeFactory.CreateScope().ServiceProvider.GetRequiredService<GetWhiteboardService>();
var whiteboard = await getWhiteboardService.GetWhiteboard(whiteboardId);
@@ -36,12 +36,12 @@ public class WhiteboardManager
{
var whiteboard = GetWhiteboard(whiteboardId);
if (whiteboard == null)
if (whiteboard is not null)
{
RemoveWhiteboard(whiteboardId);
}
await AddWhiteboard(whiteboardId);
await LoadWhiteboard(whiteboardId);
}
public Whiteboard? GetWhiteboard(Guid whiteboardId)