MCPcopy Create free account
hub / github.com/SethGammon/Citadel / detectLayer

Function detectLayer

hooks_src/post-edit.js:219–225  ·  view source on GitHub ↗
(relativePath)

Source from the content-addressed store, hash-verified

217 while ((match = importRegex.exec(content)) !== null) {
218 const importedAlias = match[1];
219 const violation = checkLayerViolation(layer, importedAlias);
220 if (violation) {
221 warnings.push(violation);
222 }
223 }
224
225 if (warnings.length > 0) {
226 hookOutput('post-edit', 'warned',
227 `[structural] ${relativePath}:\n` + warnings.map(w => ` - ${w}`).join('\n') + '\n',
228 { file: relativePath, warnings, lens: 'structural' });

Callers 1

structuralLintFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected