mirror of
https://github.com/MightyPirates/OpenComputers.git
synced 2025-09-15 10:21:45 -04:00
crash the game instead of loading defaults if config file present but invalid; close #3068
This commit is contained in:
parent
dee3bdeab4
commit
e652fd8df1
@ -518,7 +518,7 @@ object Settings {
|
|||||||
catch {
|
catch {
|
||||||
case e: Throwable =>
|
case e: Throwable =>
|
||||||
if (file.exists()) {
|
if (file.exists()) {
|
||||||
OpenComputers.log.warn("Failed loading config, using defaults.", e)
|
throw new RuntimeException("Error parsing configuration file. To restore defaults, delete '" + file.getName + "' and restart the game.", e)
|
||||||
}
|
}
|
||||||
settings = new Settings(defaults.getConfig("opencomputers"))
|
settings = new Settings(defaults.getConfig("opencomputers"))
|
||||||
defaults
|
defaults
|
||||||
|
Loading…
x
Reference in New Issue
Block a user