backthread 0.2.1 → 0.2.2

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.
@@ -2,7 +2,7 @@
2
2
  "name": "backthread",
3
3
  "displayName": "Backthread",
4
4
  "description": "Backthread helps you understand your codebase while AI ships features. It captures the why behind every Claude Code session so you can ask \"how does X work?\" without digging through PRs.",
5
- "version": "0.2.1",
5
+ "version": "0.2.2",
6
6
  "author": {
7
7
  "name": "Backthread"
8
8
  },
@@ -7306,9 +7306,9 @@ function redactCodeFences(text) {
7306
7306
  return { text: out, count };
7307
7307
  }
7308
7308
  function extractText(rec) {
7309
- if (rec.type !== "user" && rec.type !== "assistant") return null;
7309
+ const role = rec.type ?? rec.role ?? rec.message?.role;
7310
+ if (role !== "user" && role !== "assistant") return null;
7310
7311
  const content = rec.message?.content;
7311
- const role = rec.type;
7312
7312
  if (typeof content === "string") {
7313
7313
  const t = content.trim();
7314
7314
  return t.length > 0 ? { role, text: t } : null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "backthread",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Backthread helps you understand your codebase while AI ships features. The CLI captures the why behind every AI session and lets you ask how your codebase works, right from the terminal.",
5
5
  "license": "MIT",
6
6
  "author": "Backthread",