Skip to content

Commit d35fe66

Browse files
committed
fix: remove empty rootDir from key
1 parent 05f2811 commit d35fe66

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

index.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,19 @@
11
const fs = require("fs");
2-
const path = require("path");
32
const crypto = require("crypto");
43
const crossSpawn = require("cross-spawn");
54
const stripIndent = require("common-tags/lib/stripIndent");
65
const THIS_FILE = fs.readFileSync(__filename);
76

87
module.exports = {
9-
getCacheKey: (fileData, filename, configString, { instrument, rootDir }) => {
8+
getCacheKey: (fileData, filename, configString, { instrument }) => {
109
return (
1110
crypto
1211
.createHash("md5")
1312
.update(THIS_FILE)
1413
.update("\0", "utf8")
1514
.update(fileData)
1615
.update("\0", "utf8")
17-
.update(path.relative(rootDir, filename))
16+
.update(filename)
1817
.update("\0", "utf8")
1918
.update(configString)
2019
// TODO load postcssrc (the config) sync and make it part of the cache

0 commit comments

Comments
 (0)