MCPcopy Index your code
hub / github.com/Acode-Foundation/Acode / jsCompare

Function jsCompare

src/lib/editorFile.js:1093–1097  ·  view source on GitHub ↗
(fileUri)

Source from the content-addressed store, hash-verified

1091
1092 // Helper for JS-based comparison (used as fallback)
1093 const jsCompare = async (fileUri) => {
1094 const fs = fsOperation(fileUri);
1095 const oldText = await fs.readFile(this.encoding);
1096 return await system.compareTexts(oldText, text);
1097 };
1098
1099 if (/s?ftp:/.test(protocol)) {
1100 // FTP/SFTP files use cached local file

Callers 1

editorFile.jsFile · 0.85

Calls 3

fsOperationFunction · 0.85
compareTextsMethod · 0.80
readFileMethod · 0.45

Tested by

no test coverage detected