Skip to content

Commit

Permalink
packager: TransformCache: do not include basename in hash
Browse files Browse the repository at this point in the history
Reviewed By: cpojer

Differential Revision: D4867411

fbshipit-source-id: ece5214ee9cf152e23790c70f7a8b12060725150
  • Loading branch information
Jean Lauliac authored and facebook-github-bot committed Apr 11, 2017
1 parent 3184f31 commit cb88df0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packager/src/lib/TransformCache.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ function getCacheFilePaths(props: {
.update(props.transformOptionsKey);
const hash = hasher.digest('hex');
const prefix = hash.substr(0, 2);
const fileName = `${hash.substr(2)}${path.basename(props.filePath)}`;
const fileName = `${hash.substr(2)}`;
const base = path.join(getCacheDirPath(), prefix, fileName);
return {transformedCode: base, metadata: base + '.meta'};
}
Expand Down

0 comments on commit cb88df0

Please sign in to comment.