Skip to content
This repository was archived by the owner on Dec 5, 2019. It is now read-only.

Commit 14d2c4c

Browse files
evilebottnawimichael-ciniawsky
authored andcommitted
perf(index): switch to md4 for content hashing (#243)
1 parent 9f66276 commit 14d2c4c

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

Diff for: src/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ class UglifyJsPlugin {
154154
'uglifyjs-webpack-plugin': versions.plugin,
155155
'uglifyjs-webpack-plugin-options': this.options,
156156
path: compiler.outputPath ? `${compiler.outputPath}/${file}` : file,
157-
hash: crypto.createHash('md5').update(input).digest('hex'),
157+
hash: crypto.createHash('md4').update(input).digest('hex'),
158158
});
159159
}
160160

Diff for: test/__snapshots__/cache-options.test.js.snap

+8-8
Original file line numberDiff line numberDiff line change
@@ -23,56 +23,56 @@ exports[`cache \`true\`: asset manifest.6afe1bc6685e9ab36c1c.js 1`] = `"!functio
2323
exports[`cache \`true\`: cached entry test.js 1`] = `
2424
Array [
2525
"test.js",
26-
"46adcef6cf434fbddbc275218b3e093a",
26+
"28e4d31993a4f0bf5420d06d6e6013b8",
2727
]
2828
`;
2929

3030
exports[`cache \`true\`: cached entry test.js 2`] = `
3131
Array [
3232
"test.js",
33-
"46adcef6cf434fbddbc275218b3e093a",
33+
"28e4d31993a4f0bf5420d06d6e6013b8",
3434
]
3535
`;
3636

3737
exports[`cache \`true\`: cached entry test1.js 1`] = `
3838
Array [
3939
"test1.js",
40-
"6b6ccbbe331608e36cded49fd411c373",
40+
"0ee8d6a0ecdd7bc2322d1e726ef41cdd",
4141
]
4242
`;
4343

4444
exports[`cache \`true\`: cached entry test1.js 2`] = `
4545
Array [
4646
"test1.js",
47-
"6b6ccbbe331608e36cded49fd411c373",
47+
"0ee8d6a0ecdd7bc2322d1e726ef41cdd",
4848
]
4949
`;
5050

5151
exports[`cache \`true\`: cached entry test2.js 1`] = `
5252
Array [
5353
"test2.js",
54-
"975b72a762ef408dcf46a574fead7e60",
54+
"ba96de0d701dab1af6ca647f97d42fb7",
5555
]
5656
`;
5757

5858
exports[`cache \`true\`: cached entry test2.js 2`] = `
5959
Array [
6060
"test2.js",
61-
"975b72a762ef408dcf46a574fead7e60",
61+
"ba96de0d701dab1af6ca647f97d42fb7",
6262
]
6363
`;
6464

6565
exports[`cache \`true\`: cached entry test3.js 1`] = `
6666
Array [
6767
"test3.js",
68-
"fa894d635dc764c42fb6b1d4e3f6ed2b",
68+
"ef8b436e106d1bbfe07b50263e91deac",
6969
]
7070
`;
7171

7272
exports[`cache \`true\`: cached entry test3.js 2`] = `
7373
Array [
7474
"test3.js",
75-
"fa894d635dc764c42fb6b1d4e3f6ed2b",
75+
"ef8b436e106d1bbfe07b50263e91deac",
7676
]
7777
`;
7878

0 commit comments

Comments
 (0)