claude-bridge-cli 1.2.2 → 1.2.3
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/lib/bridge.js +6 -2
- package/package.json +1 -1
package/lib/bridge.js
CHANGED
|
@@ -540,8 +540,12 @@ function startBridge(config) {
|
|
|
540
540
|
if (req.method === "PATCH" || req.method === "POST") {
|
|
541
541
|
const body = await readBody(req);
|
|
542
542
|
const sess = allMarks[m[1]] || {};
|
|
543
|
-
|
|
544
|
-
sess[
|
|
543
|
+
if (body.key && body.mark) {
|
|
544
|
+
sess[body.key] = { ...(sess[body.key] || {}), ...body.mark };
|
|
545
|
+
} else {
|
|
546
|
+
for (const [k, v] of Object.entries(body)) {
|
|
547
|
+
sess[k] = { ...(sess[k] || {}), ...v };
|
|
548
|
+
}
|
|
545
549
|
}
|
|
546
550
|
allMarks[m[1]] = sess;
|
|
547
551
|
writeJson(marksFile, allMarks);
|
package/package.json
CHANGED