next-issue 6.6.83 → 6.6.84

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.
@@ -11,6 +11,7 @@ export function parseResolved(text) {
11
11
  return note === undefined || PLACEHOLDERS.has(note.toLowerCase()) ? undefined : note;
12
12
  }
13
13
  const CLOSING_REFERENCE = /(\s*[,;]?\s*(?:and\s+)?)\b(close[sd]?|fix(?:e[sd])?|resolve[sd]?)(\s*:\s*|\s+)(?:[\w.-]+\/[\w.-]+#\d+|#\d+|https?:\/\/\S+\/(?:issues|pull)\/\d+)/gi;
14
+ const BARE_TYPE = /^\w+(?:\([^)]*\))?!?$/;
14
15
  export function withoutClosingReferences(subject, fallback) {
15
16
  const cleaned = subject
16
17
  .replace(CLOSING_REFERENCE, (_match, _lead, keyword, separator, offset) => offset === 0 && separator.includes(':') ? `${keyword}: ` : '')
@@ -18,7 +19,8 @@ export function withoutClosingReferences(subject, fallback) {
18
19
  .replace(/\s+/g, ' ')
19
20
  .replace(/[\s,;:]+$/, '')
20
21
  .trim();
21
- return cleaned || fallback;
22
+ const onlyType = subject.search(CLOSING_REFERENCE) !== -1 && BARE_TYPE.test(cleaned);
23
+ return cleaned && !onlyType ? cleaned : fallback;
22
24
  }
23
25
  export function parseCommitSubject(text, fallback) {
24
26
  const subject = lastMatch(text, /^commit:[^\S\r\n]*(.*)$/gim)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "next-issue",
3
- "version": "6.6.83",
3
+ "version": "6.6.84",
4
4
  "description": "Autonomous issue harness driven by the pi SDK",
5
5
  "keywords": [
6
6
  "github",