MCPcopy Index your code
hub / github.com/callstack/agent-device / readStructuredBatchCommandName

Function readStructuredBatchCommandName

src/batch-policy.ts:57–67  ·  view source on GitHub ↗
(
  command: unknown,
  stepNumber: number,
)

Source from the content-addressed store, hash-verified

55}
56
57export function readStructuredBatchCommandName(
58 command: unknown,
59 stepNumber: number,
60): StructuredBatchCommandName {
61 const normalized = normalizeBatchCommandName(command);
62 if (isStructuredBatchCommandName(normalized)) return normalized;
63 throw new AppError(
64 'INVALID_ARGS',
65 `Batch step ${stepNumber} command is not available through command batch: ${String(command)}`,
66 );
67}
68
69export function assertBatchRuntimeCommandAllowed(command: string, stepNumber: number): void {
70 if (BATCH_BLOCKED_COMMANDS.has(command)) {

Callers 2

readBatchStepCommandFunction · 0.90
readBatchStepCommandFunction · 0.90

Calls 2

Tested by

no test coverage detected