fix: import readBody+sendJson in server.ts — POST /pair was crashing

This commit is contained in:
Johannes Merz 2026-05-16 03:04:07 +02:00
parent 571cf8c9ec
commit 920f6d8fc3
1 changed files with 2 additions and 2 deletions

View File

@ -51,7 +51,7 @@ import { handleInput } from "./routes/input.js";
import { handleSessions } from "./routes/sessions.js";
import type { RemoteServer, WsClient, WsServer } from "./types.js";
import { createUpgradeHandler } from "./upgrade.js";
import { extractBearer } from "./util.js";
import { extractBearer, readBody, sendJson } from "./util.js";
// ---------------------------------------------------------------------------
// Load ws (bundled with pi) without needing @types/ws installed locally
@ -257,7 +257,7 @@ export async function startServer(
host,
port,
pairingToken: pairingEntry.token,
fingerprint: "",
fingerprint: "NO-TLS-YET-REPLACE-IN-T-1-3",
sidecarName: "pi-remote",
});
res.writeHead(200, { "Content-Type": "text/plain; charset=utf-8" });