MCPcopy Create free account
hub / github.com/RioArisk/claudecode_api_RemoteControl / cacheTurnState

Function cacheTurnState

app/src/modules/renderer.js:243–249  ·  view source on GitHub ↗
(state)

Source from the content-addressed store, hash-verified

241
242// ---- Turn state ----
243export function cacheTurnState(state) {
244 if (!state) return;
245 const nextVersion = Number.isInteger(state.version) ? state.version : 0;
246 const pendingVersion = Number.isInteger(S.pendingTurnState?.version) ? S.pendingTurnState.version : -1;
247 if (nextVersion < pendingVersion) return;
248 S.pendingTurnState = state;
249}
250
251export function applyTurnState(state, reason = '') {
252 if (!state) return;

Callers 1

connectFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected