Skip to content

Commit 7fab952

Browse files
committed
perf(config): avoid recursive md4 patching
1 parent 98cd356 commit 7fab952

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/config/src/options.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -520,7 +520,7 @@ export function getNuxtConfig (_options) {
520520
}
521521

522522
// Monkey patch crypto.createHash in dev/build to upgrade hashing fnction
523-
if (parseInt(process.versions.node.slice(0, 2)) > 16) {
523+
if (parseInt(process.versions.node.slice(0, 2)) > 16 && !options.buildModules.some(m => m.name === 'patchMD4')) {
524524
options.buildModules.push(function patchMD4 () {
525525
const crypto = require('crypto')
526526
const _createHash = crypto.createHash

0 commit comments

Comments
 (0)