Skip to content

Commit

Permalink
fix: synchronized client features creation to avoid loosing register
Browse files Browse the repository at this point in the history
capability.

Signed-off-by: azerr <[email protected]>
  • Loading branch information
angelozerr committed Oct 24, 2024
1 parent 67f8e68 commit 3aee93d
Show file tree
Hide file tree
Showing 21 changed files with 390 additions and 113 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,7 @@ public synchronized void start() throws LanguageServerException {
.thenAccept(res -> {
serverError = null;
serverCapabilities = res.getCapabilities();
getClientFeatures().setServerCapabilities(serverCapabilities);
this.initiallySupportsWorkspaceFolders = supportsWorkspaceFolders(serverCapabilities);
}).thenRun(() -> this.languageServer.initialized(new InitializedParams())).thenRun(() -> {
initializeFuture.thenRunAsync(() -> {
Expand All @@ -311,7 +312,6 @@ public synchronized void start() throws LanguageServerException {

fileOperationsManager = new FileOperationsManager(this);
fileOperationsManager.setServerCapabilities(serverCapabilities);
getClientFeatures().setServerCapabilities(serverCapabilities);

updateStatus(ServerStatus.started);
getLanguageServerLifecycleManager().onStatusChanged(this);
Expand Down
Loading

0 comments on commit 3aee93d

Please sign in to comment.