diff --git a/java/java-impl/src/com/intellij/codeInsight/javadoc/JavaDocInfoGenerator.java b/java/java-impl/src/com/intellij/codeInsight/javadoc/JavaDocInfoGenerator.java index 35c288a566e4..fce44042176e 100644 --- a/java/java-impl/src/com/intellij/codeInsight/javadoc/JavaDocInfoGenerator.java +++ b/java/java-impl/src/com/intellij/codeInsight/javadoc/JavaDocInfoGenerator.java @@ -232,10 +232,13 @@ public class JavaDocInfoGenerator { return null; } if (docURLs != null) { - StringBuffer errorsSection = new StringBuffer("

Following external urls were checked:
   "); + StringBuilder errorsSection = new StringBuilder("

Following external urls were checked:
   "); errorsSection.append(StringUtil.join(docURLs, "
   ")); errorsSection.append("
The documentation for this element is not found. Please add all the needed paths to API docs in "); errorsSection.append("Project Settings.

"); + if (buffer.length() == 0) { + buffer.append(""); + } buffer.insert(buffer.indexOf(""), errorsSection.toString()); } return fixupDoc(buffer);