ework-web 0.10.26 → 0.10.27
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.
- package/package.json +1 -1
- package/src/index.ts +3 -1
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -627,8 +627,10 @@ async function handle(req: Request, url: URL, ip: string, ctx: { authed: boolean
|
|
|
627
627
|
const desc = url.searchParams.get("asc") !== "1";
|
|
628
628
|
const all = url.searchParams.get("all") === "1";
|
|
629
629
|
const limit = Math.min(5000, Math.max(1, Number(url.searchParams.get("limit")) || 30));
|
|
630
|
+
const daemonEp = url.searchParams.get("daemon");
|
|
631
|
+
const client = daemonEp ? new RemoteOpencodeClient(daemonEp) : opencode;
|
|
630
632
|
try {
|
|
631
|
-
const { html: body } = await buildSessionView(
|
|
633
|
+
const { html: body } = await buildSessionView(client, sid, desc, cfg.collapseLines, limit, all);
|
|
632
634
|
return html(body);
|
|
633
635
|
} catch (e) {
|
|
634
636
|
const status = e instanceof OpencodeError ? e.status : 500;
|