MCPcopy Index your code
hub / github.com/codeaashu/claude-code / containsControlChars

Function containsControlChars

src/utils/deepLink/parseDeepLink.ts:36–44  ·  view source on GitHub ↗

* Check if a string contains ASCII control characters (0x00-0x1F, 0x7F). * These can act as command separators in shells (newlines, carriage returns, etc.). * Allows printable ASCII and Unicode (CJK, emoji, accented chars, etc.).

(s: string)

Source from the content-addressed store, hash-verified

34 * Allows printable ASCII and Unicode (CJK, emoji, accented chars, etc.).
35 */
36function containsControlChars(s: string): boolean {
37 for (let i = 0; i < s.length; i++) {
38 const code = s.charCodeAt(i)
39 if (code <= 0x1f || code === 0x7f) {
40 return true
41 }
42 }
43 return false
44}
45
46/**
47 * GitHub owner/repo slug: alphanumerics, dots, hyphens, underscores,

Callers 1

parseDeepLinkFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected