Set appropriate file stat times (#763)
* Set appropriate file stat times Since we are creating the destination file, it's our responsibility to set the file stat times. * fix code style
This commit is contained in:
parent
7ab018e367
commit
ebe3ec6b5e
4
index.js
4
index.js
|
@ -99,6 +99,10 @@ const gulpSass = (options, sync) => through.obj((file, enc, cb) => { // eslint-d
|
||||||
file.contents = sassObj.css; // eslint-disable-line no-param-reassign
|
file.contents = sassObj.css; // eslint-disable-line no-param-reassign
|
||||||
file.path = replaceExtension(file.path, '.css'); // eslint-disable-line no-param-reassign
|
file.path = replaceExtension(file.path, '.css'); // eslint-disable-line no-param-reassign
|
||||||
|
|
||||||
|
if (file.stat) {
|
||||||
|
file.stat.atime = file.stat.mtime = file.stat.ctime = new Date(); // eslint-disable-line
|
||||||
|
}
|
||||||
|
|
||||||
cb(null, file);
|
cb(null, file);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue