diff --git a/dist/index.js b/dist/index.js index 64aed12..56e93f8 100644 --- a/dist/index.js +++ b/dist/index.js @@ -59272,8 +59272,10 @@ function renameSystem32Dlls() { const sys32 = 'C:\\Windows\\System32\\' const badFiles = [`${sys32}libcrypto-1_1-x64.dll`, `${sys32}libssl-1_1-x64.dll`] const existing = badFiles.filter((dll) => fs.existsSync(dll)) - console.log(`Renaming ${existing.join(' and ')} to avoid dll resolution conflicts on Ruby <= 2.4`) - existing.forEach(dll => fs.renameSync(dll, `${dll}_`)) + if (existing.length > 0) { + console.log(`Renaming ${existing.join(' and ')} to avoid dll resolution conflicts on Ruby <= 2.4`) + existing.forEach(dll => fs.renameSync(dll, `${dll}_`)) + } } // Sets MSYS2 ENV variables set from running `ridk enable` diff --git a/windows.js b/windows.js index 3c11e69..0226109 100644 --- a/windows.js +++ b/windows.js @@ -243,8 +243,10 @@ function renameSystem32Dlls() { const sys32 = 'C:\\Windows\\System32\\' const badFiles = [`${sys32}libcrypto-1_1-x64.dll`, `${sys32}libssl-1_1-x64.dll`] const existing = badFiles.filter((dll) => fs.existsSync(dll)) - console.log(`Renaming ${existing.join(' and ')} to avoid dll resolution conflicts on Ruby <= 2.4`) - existing.forEach(dll => fs.renameSync(dll, `${dll}_`)) + if (existing.length > 0) { + console.log(`Renaming ${existing.join(' and ')} to avoid dll resolution conflicts on Ruby <= 2.4`) + existing.forEach(dll => fs.renameSync(dll, `${dll}_`)) + } } // Sets MSYS2 ENV variables set from running `ridk enable`