Remove cache option from readAndWatchFileWithHash

This commit is contained in:
zodern
2022-02-04 13:46:59 -06:00
parent 64bbff2a18
commit eb9a5864cb

View File

@@ -87,23 +87,16 @@ export class CssFile extends InputFile {
this._minifiedFiles.push({ ...options });
}
readAndWatchFileWithHash(path, { cache } = {}) {
readAndWatchFileWithHash(path) {
const filePath = convertToPosixPath(path);
if (cache) {
const hash = optimisticHashOrNull(filePath);
const contents = optimisticReadFile(filePath);
this._watchSet.addFile(filePath, hash);
const hash = optimisticHashOrNull(filePath);
const contents = optimisticReadFile(filePath);
this._watchSet.addFile(filePath, hash);
return {
hash,
contents
}
return {
hash,
contents
}
return readAndWatchFileWithHash(
this._watchSet,
filePath,
);
}
}