diff --git a/pom.xml b/pom.xml
index d99cebc9b..b7b24a6d8 100644
--- a/pom.xml
+++ b/pom.xml
@@ -9,7 +9,7 @@
org.sonarsource.sonarlint.ls
sonarlint-language-server
- 3.14-SNAPSHOT
+ 3.13.1-SNAPSHOT
jar
SonarLint Language Server
SonarLint Language Server
@@ -24,7 +24,7 @@
17
- 10.11.0.79687
+ 10.11.1.79701
1.6.10
diff --git a/src/main/java/org/sonarsource/sonarlint/ls/file/VersionedOpenFile.java b/src/main/java/org/sonarsource/sonarlint/ls/file/VersionedOpenFile.java
index 06f8c831b..784758c15 100644
--- a/src/main/java/org/sonarsource/sonarlint/ls/file/VersionedOpenFile.java
+++ b/src/main/java/org/sonarsource/sonarlint/ls/file/VersionedOpenFile.java
@@ -20,6 +20,7 @@
package org.sonarsource.sonarlint.ls.file;
import java.net.URI;
+import javax.annotation.Nullable;
import javax.annotation.concurrent.Immutable;
import org.apache.commons.lang3.builder.ToStringBuilder;
@@ -33,7 +34,7 @@ public class VersionedOpenFile {
private final int version;
private final String content;
- public VersionedOpenFile(URI uri, String languageId, int version, String content) {
+ public VersionedOpenFile(URI uri, @Nullable String languageId, int version, @Nullable String content) {
this.uri = uri;
this.languageId = languageId;
this.version = version;
@@ -44,6 +45,7 @@ public URI getUri() {
return uri;
}
+ @Nullable
public String getLanguageId() {
return languageId;
}
@@ -52,6 +54,7 @@ public int getVersion() {
return version;
}
+ @Nullable
public String getContent() {
return content;
}
diff --git a/src/main/java/org/sonarsource/sonarlint/ls/folders/ModuleEventsProcessor.java b/src/main/java/org/sonarsource/sonarlint/ls/folders/ModuleEventsProcessor.java
index 560a2d759..5f59242bc 100644
--- a/src/main/java/org/sonarsource/sonarlint/ls/folders/ModuleEventsProcessor.java
+++ b/src/main/java/org/sonarsource/sonarlint/ls/folders/ModuleEventsProcessor.java
@@ -79,7 +79,7 @@ private void notifyBackend(List changes) {
if (event.getType() == FileChangeType.Deleted) {
deletedFileUris.add(fileUri);
} else {
- var clientFileDto = getClientFileDto(new VersionedOpenFile(fileUri, "", 0, ""));
+ var clientFileDto = getClientFileDto(new VersionedOpenFile(fileUri, null, 0, null));
if (event.getType() == FileChangeType.Created) {
addedFiles.add(clientFileDto);
} else {
@@ -107,7 +107,8 @@ ClientFileDto getClientFileDto(VersionedOpenFile file) {
AtomicReference clientFileDto = new AtomicReference<>();
var fileUri = file.getUri();
var fsPath = Paths.get(fileUri);
- SonarLanguage sqLanguage = AnalysisClientInputFile.toSqLanguage(file.getLanguageId().toLowerCase(Locale.ROOT));
+ SonarLanguage sqLanguage = file.getLanguageId() != null ?
+ AnalysisClientInputFile.toSqLanguage(file.getLanguageId().toLowerCase(Locale.ROOT)) : null;
workspaceFoldersManager.findFolderForFile(fileUri)
.ifPresentOrElse(folder -> {
var settings = folder.getSettings();