MCPcopy Index your code
hub / github.com/getsentry/XcodeBuildMCP / clampIndex

Function clampIndex

src/cli/interactive/prompts.ts:25–28  ·  view source on GitHub ↗
(index: number, optionsLength: number)

Source from the content-addressed store, hash-verified

23}
24
25function clampIndex(index: number, optionsLength: number): number {
26 if (optionsLength <= 0) return 0;
27 return Math.max(0, Math.min(index, optionsLength - 1));
28}
29
30function createNonInteractivePrompter(): Prompter {
31 return {

Callers 1

selectOneFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected