MCPcopy Index your code
hub / github.com/anomalyco/opencode / mergePatch

Function mergePatch

packages/opencode/src/cli/cmd/run/session-replay.ts:45–58  ·  view source on GitHub ↗
(left: FooterPatch | undefined, right: FooterPatch | undefined)

Source from the content-addressed store, hash-verified

43}
44
45function mergePatch(left: FooterPatch | undefined, right: FooterPatch | undefined) {
46 if (!left) {
47 return right
48 }
49
50 if (!right) {
51 return left
52 }
53
54 return {
55 ...left,
56 ...right,
57 }
58}
59
60function active(data: SessionData) {
61 return data.part.size > 0 || data.tools.size > 0

Callers 2

replayMessageFunction · 0.85
replaySessionFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected