pi-interview 0.5.3 → 0.5.4

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/schema.ts +3 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-interview",
3
- "version": "0.5.3",
3
+ "version": "0.5.4",
4
4
  "description": "Interactive interview form extension for pi coding agent",
5
5
  "author": "Nico Bailon",
6
6
  "license": "MIT",
package/schema.ts CHANGED
@@ -311,6 +311,9 @@ export function validateQuestions(data: unknown): QuestionsFile {
311
311
  const optionLabels = q.options?.map(getOptionLabel) ?? [];
312
312
 
313
313
  if (q.type === "single") {
314
+ if (Array.isArray(q.recommended) && q.recommended.length === 1) {
315
+ q.recommended = q.recommended[0];
316
+ }
314
317
  if (typeof q.recommended !== "string") {
315
318
  throw new Error(`Question "${q.id}": recommended must be string for single-select`);
316
319
  }