mirror of
https://github.com/EngineHub/WorldGuard.git
synced 2024-12-05 00:43:49 +01:00
Formatting fix.
This commit is contained in:
parent
47fb9bd30d
commit
0ebb4e0ffa
@ -417,8 +417,7 @@ private void configureLogger() {
|
|||||||
* @param actual The destination file
|
* @param actual The destination file
|
||||||
* @param defaultName The name of the file inside the jar's defaults folder
|
* @param defaultName The name of the file inside the jar's defaults folder
|
||||||
*/
|
*/
|
||||||
public void createDefaultConfiguration(File actual,
|
public void createDefaultConfiguration(File actual, String defaultName) {
|
||||||
String defaultName) {
|
|
||||||
|
|
||||||
// Make parent directories
|
// Make parent directories
|
||||||
File parent = actual.getParentFile();
|
File parent = actual.getParentFile();
|
||||||
@ -430,16 +429,15 @@ public void createDefaultConfiguration(File actual,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
InputStream input =
|
InputStream input = null;
|
||||||
null;
|
try {
|
||||||
try {
|
JarFile file = new JarFile(getFile());
|
||||||
JarFile file = new JarFile(getFile());
|
ZipEntry copy = file.getEntry("defaults/" + defaultName);
|
||||||
ZipEntry copy = file.getEntry("defaults/" + defaultName);
|
if (copy == null) throw new FileNotFoundException();
|
||||||
if (copy == null) throw new FileNotFoundException();
|
input = file.getInputStream(copy);
|
||||||
input = file.getInputStream(copy);
|
} catch (IOException e) {
|
||||||
} catch (IOException e) {
|
WorldGuard.logger.severe("Unable to read default configuration: " + defaultName);
|
||||||
WorldGuard.logger.severe("Unable to read default configuration: " + defaultName);
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (input != null) {
|
if (input != null) {
|
||||||
FileOutputStream output = null;
|
FileOutputStream output = null;
|
||||||
|
Loading…
Reference in New Issue
Block a user