diff --git a/pom.xml b/pom.xml
index 3b53d51..faec2b4 100644
--- a/pom.xml
+++ b/pom.xml
@@ -5,7 +5,7 @@
com.pablissimo.sonar
sonar-typescript-plugin
sonar-plugin
- 0.96-SNAPSHOT
+ 0.97-SNAPSHOT
TypeScript
Analyse TypeScript projects
diff --git a/src/main/java/com/pablissimo/sonar/TsLintParserImpl.java b/src/main/java/com/pablissimo/sonar/TsLintParserImpl.java
index 864d99e..43390c6 100644
--- a/src/main/java/com/pablissimo/sonar/TsLintParserImpl.java
+++ b/src/main/java/com/pablissimo/sonar/TsLintParserImpl.java
@@ -23,6 +23,11 @@ public Map> parse(List toParse) {
for (String batch : toParse) {
TsLintIssue[] batchIssues = gson.fromJson(getFixedUpOutput(batch), TsLintIssue[].class);
+
+ if (batchIssues == null) {
+ continue;
+ }
+
for (TsLintIssue batchIssue : batchIssues) {
allIssues.add(batchIssue);
}
diff --git a/src/test/java/com/pablissimo/sonar/TsLintParserTest.java b/src/test/java/com/pablissimo/sonar/TsLintParserTest.java
index ae1ca53..625eb54 100644
--- a/src/test/java/com/pablissimo/sonar/TsLintParserTest.java
+++ b/src/test/java/com/pablissimo/sonar/TsLintParserTest.java
@@ -67,4 +67,14 @@ public void fixesUpBrokenBatchedOutputFromTsLintPriorTo_4_0_0() {
assertEquals(1, issues.size());
assertEquals(2, issues.get("Tools.ts").size());
}
+
+ @Test
+ public void parseAGoodProjectWithNoIssues() {
+ List toParse = new ArrayList();
+ toParse.add("");
+
+ Map> issues = new TsLintParserImpl().parse(toParse);
+
+ assertEquals(0, issues.size());
+ }
}