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

Commit 25b4a54

Browse files
authored
Merge pull request #96 from DeathsGun/bugs/95_nosuchfile
Ignore exceptions while deleting mods
2 parents 4b0497a + f3e604b commit 25b4a54

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/main/kotlin/xyz/deathsgun/modmanager/PreLaunchHook.kt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,10 @@ class PreLaunchHook : PreLaunchEntrypoint {
3939
for (file in filesToDelete) {
4040
logger.info("Deleting {}", file)
4141
val path = Path(file)
42-
Files.delete(path)
42+
try {
43+
Files.delete(path)
44+
} catch (e: Exception) { // Ignore it
45+
}
4346
}
4447
}
4548

0 commit comments

Comments
 (0)