MCPcopy Index your code
hub / github.com/simstudioai/sim / sanitizeIdentifier

Function sanitizeIdentifier

apps/sim/app/api/tools/postgresql/utils.ts:65–72  ·  view source on GitHub ↗
(identifier: string)

Source from the content-addressed store, hash-verified

63}
64
65export function sanitizeIdentifier(identifier: string): string {
66 if (identifier.includes('.')) {
67 const parts = identifier.split('.')
68 return parts.map((part) => sanitizeSingleIdentifier(part)).join('.')
69 }
70
71 return sanitizeSingleIdentifier(identifier)
72}
73
74/**
75 * Validates a WHERE clause to prevent SQL injection attacks

Callers 3

executeInsertFunction · 0.70
executeUpdateFunction · 0.70
executeDeleteFunction · 0.70

Calls 2

joinMethod · 0.80
sanitizeSingleIdentifierFunction · 0.70

Tested by

no test coverage detected