MCPcopy
hub / github.com/sequelize/sequelize / isBackslashEscaped

Function isBackslashEscaped

src/utils/sql.ts:244–256  ·  view source on GitHub ↗
(string: string, pos: number)

Source from the content-addressed store, hash-verified

242}
243
244function isBackslashEscaped(string: string, pos: number): boolean {
245 let escaped = false;
246 for (let i = pos; i >= 0; i--) {
247 const char = string[i];
248 if (char !== '\\') {
249 break;
250 }
251
252 escaped = !escaped;
253 }
254
255 return escaped;
256}

Callers 1

injectReplacementsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected