--- a/eric6/Plugins/CheckerPlugins/CodeStyleChecker/DocStyle/DocStyleChecker.py Sun Apr 11 16:53:48 2021 +0200 +++ b/eric6/Plugins/CheckerPlugins/CodeStyleChecker/DocStyle/DocStyleChecker.py Sun Apr 11 18:45:10 2021 +0200 @@ -972,9 +972,11 @@ return summary, lineNumber = self.__getSummaryLine(docstringContext) - if len(docstrings) > 2: - if docstrings[lineNumber + 1].strip(): - self.__error(docstringContext.start() + lineNumber, 0, "D144") + if ( + len(docstrings) > 2 and + docstrings[lineNumber + 1].strip() + ): + self.__error(docstringContext.start() + lineNumber, 0, "D144") def __checkBlankAfterLastParagraph(self, docstringContext, context): """ @@ -1285,9 +1287,11 @@ return summaryLines, lineNumber = self.__getSummaryLines(docstringContext) - if len(docstrings) - 2 > lineNumber + len(summaryLines) - 1: - if docstrings[lineNumber + len(summaryLines)].strip(): - self.__error(docstringContext.start() + lineNumber, 0, "D246") + if ( + len(docstrings) - 2 > lineNumber + len(summaryLines) - 1 and + docstrings[lineNumber + len(summaryLines)].strip() + ): + self.__error(docstringContext.start() + lineNumber, 0, "D246") def __checkEricNoBlankBeforeAndAfterClassOrFunction( self, docstringContext, context):