diff --git a/src/PowerShellEditorServices/Server/PsesLanguageServer.cs b/src/PowerShellEditorServices/Server/PsesLanguageServer.cs index afc739d1c..b454a190a 100644 --- a/src/PowerShellEditorServices/Server/PsesLanguageServer.cs +++ b/src/PowerShellEditorServices/Server/PsesLanguageServer.cs @@ -111,7 +111,7 @@ public async Task StartAsync() var workspaceService = serviceProvider.GetService(); // Grab the workspace path from the parameters - workspaceService.WorkspacePath = request.RootUri.LocalPath; + workspaceService.WorkspacePath = request.RootUri?.LocalPath; // Set the working directory of the PowerShell session to the workspace path if (workspaceService.WorkspacePath != null