@haystackeditor/cli 0.15.4 → 0.15.5

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.
@@ -164,8 +164,8 @@ class JsonPrompter {
164
164
  if (!obj || typeof obj !== 'object')
165
165
  return;
166
166
  // Mirror OpenCode: question replies are keyed by `requestID`, permission
167
- // replies by `permissionID`. Legacy `id` accepted too.
168
- const key = (obj.requestID ?? obj.permissionID ?? obj.id);
167
+ // replies by `permissionID`.
168
+ const key = (obj.requestID ?? obj.permissionID);
169
169
  if (typeof key !== 'string')
170
170
  return;
171
171
  const resolve = this.pending.get(key);
@@ -199,7 +199,7 @@ class JsonPrompter {
199
199
  // string "false" isn't coerced truthy.
200
200
  if (reply.reject)
201
201
  throw new PromptCancelledError(q.id);
202
- return toBool(reply.answers ?? reply.value);
202
+ return toBool(reply.answers);
203
203
  }
204
204
  async multiselect(q) {
205
205
  if (q.id in this.answers)
@@ -215,7 +215,7 @@ class JsonPrompter {
215
215
  // than silently coercing to [] (PR001: no silent fallback).
216
216
  if (reply.reject)
217
217
  throw new PromptCancelledError(q.id);
218
- return asArray(reply.answers ?? reply.value, q.id);
218
+ return asArray(reply.answers, q.id);
219
219
  }
220
220
  async action(q) {
221
221
  if (this.answers[q.id] === 'skip')
@@ -232,8 +232,8 @@ class JsonPrompter {
232
232
  let override = null;
233
233
  this.ensureStdin();
234
234
  const answerPromise = this.awaitReply(q.id).then((reply) => {
235
- const r = (reply.response ?? reply.value);
236
- override = r === 'reject' || r === 'skip' ? 'skip' : 'done';
235
+ const r = reply.response;
236
+ override = r === 'reject' ? 'skip' : 'done';
237
237
  });
238
238
  try {
239
239
  while (Date.now() - started < timeout) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@haystackeditor/cli",
3
- "version": "0.15.4",
3
+ "version": "0.15.5",
4
4
  "description": "Set up Haystack for your project — automated PR review, triage, and merge queue",
5
5
  "type": "module",
6
6
  "bin": {