eslint-plugin-jsdoc 65.2.5 → 65.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -163,5 +163,5 @@
163
163
  "test-cov": "TIMING=1 c8 --reporter text pnpm run test-no-cov",
164
164
  "test-index": "pnpm run test-no-cov test/rules/index.js"
165
165
  },
166
- "version": "65.2.5"
166
+ "version": "65.2.6"
167
167
  }
@@ -38,13 +38,16 @@ const checkMaxBlockLines = ({
38
38
  },
39
39
  () => {
40
40
  utils.setBlockDescription((info, seedTokens, descLines, postDelims) => {
41
+ // The run of newlines starts at the end of the preceding text line,
42
+ // so the blank lines to drop begin after that line.
43
+ const excessStart = descLines[excessIndexLine] ? excessIndexLine + 1 : excessIndexLine;
41
44
  const newPostDelims = [
42
- ...postDelims.slice(0, excessIndexLine),
43
- ...postDelims.slice(excessIndexLine + excessBlockLines - 1 - maxBlockLines),
45
+ ...postDelims.slice(0, excessStart),
46
+ ...postDelims.slice(excessStart + excessBlockLines - 1 - maxBlockLines),
44
47
  ];
45
48
  return [
46
- ...descLines.slice(0, excessIndexLine),
47
- ...descLines.slice(excessIndexLine + excessBlockLines - 1 - maxBlockLines),
49
+ ...descLines.slice(0, excessStart),
50
+ ...descLines.slice(excessStart + excessBlockLines - 1 - maxBlockLines),
48
51
  ].map((desc, idx) => {
49
52
  return {
50
53
  number: 0,