Skip to content

Commit 7df6d27

Browse files
committed
[ci] Fix checkstyle issue with else statement
1 parent f81fb49 commit 7df6d27

File tree

1 file changed

+5
-10
lines changed

1 file changed

+5
-10
lines changed

src/main/java/org/apache/ibatis/io/DefaultVFS.java

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,7 @@ public List<String> list(URL url, String path) throws IOException {
6565
log.debug("Listing " + url);
6666
}
6767
resources = listResources(new JarInputStream(is), path);
68-
}
69-
else {
68+
} else {
7069
List<String> children = new ArrayList<>();
7170
try {
7271
if (isJar(url)) {
@@ -84,8 +83,7 @@ public List<String> list(URL url, String path) throws IOException {
8483
children.add(entry.getName());
8584
}
8685
}
87-
}
88-
else {
86+
} else {
8987
/*
9088
* Some servlet containers allow reading from directory resources like a
9189
* text file, listing the child resources one per line. However, there is no
@@ -132,8 +130,7 @@ public List<String> list(URL url, String path) throws IOException {
132130
}
133131
children = Arrays.asList(file.list());
134132
}
135-
}
136-
else {
133+
} else {
137134
// No idea where the exception came from so rethrow it
138135
throw e;
139136
}
@@ -244,8 +241,7 @@ protected URL findJarForResource(URL url) throws MalformedURLException {
244241
if (log.isDebugEnabled()) {
245242
log.debug("Extracted JAR URL: " + jarUrl);
246243
}
247-
}
248-
else {
244+
} else {
249245
if (log.isDebugEnabled()) {
250246
log.debug("Not a JAR: " + jarUrl);
251247
}
@@ -257,8 +253,7 @@ protected URL findJarForResource(URL url) throws MalformedURLException {
257253
URL testUrl = new URL(jarUrl.toString());
258254
if (isJar(testUrl)) {
259255
return testUrl;
260-
}
261-
else {
256+
} else {
262257
// WebLogic fix: check if the URL's file exists in the filesystem.
263258
if (log.isDebugEnabled()) {
264259
log.debug("Not a JAR: " + jarUrl);

0 commit comments

Comments
 (0)