MCPcopy Create free account
hub / github.com/Noumena-Network/code / checkPermissions

Function checkPermissions

src/tools/REPLTool/pyReplFactory.tsx:588–604  ·  view source on GitHub ↗
(input, context)

Source from the content-addressed store, hash-verified

586 return input.code
587 },
588 async checkPermissions(input, context): Promise<PermissionResult> {
589 const mode = context.getAppState().toolPermissionContext.mode
590 if (mode === 'acceptEdits') {
591 return {
592 behavior: 'allow',
593 updatedInput: input,
594 decisionReason: {
595 type: 'mode',
596 mode,
597 },
598 }
599 }
600 return {
601 behavior: 'passthrough',
602 updatedInput: input,
603 }
604 },
605 async prompt() {
606 return typeof config.prompt === 'function' ? config.prompt() : config.prompt
607 },

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected