mirror of
https://gitea.shironeko-all.duckdns.org/shironeko/Hytale-F2P-2.git
synced 2026-02-26 10:41:46 -03:00
fix: remove broken symlink after detected
This commit is contained in:
@@ -187,9 +187,10 @@ async function getModsPath(customInstallPath = null) {
|
||||
} catch (e) { /* ignore */ }
|
||||
|
||||
if (!isBrokenLink) {
|
||||
// Ensure the Mods directory exists
|
||||
fs.mkdirSync(modsPath, { recursive: true });
|
||||
fs.unlinkSync(modsPath); // Remove broken symlink
|
||||
}
|
||||
// Ensure the Mods directory exists
|
||||
fs.mkdirSync(modsPath, { recursive: true });
|
||||
}
|
||||
if (!fs.existsSync(disabledModsPath)) {
|
||||
fs.mkdirSync(disabledModsPath, { recursive: true });
|
||||
|
||||
Reference in New Issue
Block a user