diff --git a/src/OmniSharp.Roslyn/OmniSharpWorkspace.cs b/src/OmniSharp.Roslyn/OmniSharpWorkspace.cs index 495f88a6ca..6ed38b5f0c 100644 --- a/src/OmniSharp.Roslyn/OmniSharpWorkspace.cs +++ b/src/OmniSharp.Roslyn/OmniSharpWorkspace.cs @@ -97,7 +97,7 @@ public DocumentId TryAddMiscellaneousDocument(string filePath, string language) if (GetDocument(filePath) != null) return null; //if the workspace already knows about this document then it is not a miscellaneous document - var projectInfo = miscDocumentsProjectInfos.GetOrAdd(language, CreateMiscFilesProject(language)); + var projectInfo = miscDocumentsProjectInfos.GetOrAdd(language, (lang) => CreateMiscFilesProject(lang)); var documentId = AddDocument(projectInfo.Id, filePath); return documentId; }