From 082f2002c01721570c7fba9424c9f78ebeba114e Mon Sep 17 00:00:00 2001 From: Alexander Schwartz Date: Fri, 3 May 2019 09:59:24 +0200 Subject: [PATCH] ignore message "possible invalid reference" #249 --- .../org/asciidoc/intellij/annotator/ExternalAnnotator.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/main/java/org/asciidoc/intellij/annotator/ExternalAnnotator.java b/src/main/java/org/asciidoc/intellij/annotator/ExternalAnnotator.java index 837e050a4..386b282b0 100644 --- a/src/main/java/org/asciidoc/intellij/annotator/ExternalAnnotator.java +++ b/src/main/java/org/asciidoc/intellij/annotator/ExternalAnnotator.java @@ -83,6 +83,11 @@ public void apply(@NotNull PsiFile file, AsciidocAnnotationResultType annotation WolfTheProblemSolver theProblemSolver = WolfTheProblemSolver.getInstance(file.getProject()); Collection problems = new ArrayList<>(); for (LogRecord logRecord : annotationResult.getLogRecords()) { + if (logRecord.getMessage().startsWith("possible invalid reference:")) { + /* TODO: these messages are not helpful in IntelliJ as they have no line number + and for splitted documents they provide too many false positives */ + continue; + } HighlightSeverity severity = toSeverity(logRecord.getSeverity()); // the line number as shown in the IDE (starting with 1) Integer lineNumber = null;