Archiviert
13
0

No need to throw an exception if the "last updated" file is corrupt.

Dieser Commit ist enthalten in:
Kristian S. Stangeland 2014-02-18 21:46:42 +01:00
Ursprung 6443de6257
Commit 7503470cb1

Datei anzeigen

@ -110,14 +110,13 @@ public class ProtocolConfig {
try { try {
return Long.parseLong(Files.toString(dataFile, Charsets.UTF_8)); return Long.parseLong(Files.toString(dataFile, Charsets.UTF_8));
} catch (NumberFormatException e) { } catch (NumberFormatException e) {
throw new RuntimeException("Cannot parse " + dataFile + " as a number.", e); plugin.getLogger().warning("Cannot parse " + dataFile + " as a number.");
} catch (IOException e) { } catch (IOException e) {
throw new RuntimeException("Cannot read " + dataFile, e); plugin.getLogger().warning("Cannot read " + dataFile);
} }
} else {
// Default last update
return 0;
} }
// Default last update
return 0;
} }
/** /**