Replace string arguments with char
Optimize method calls by replacing single character String arguments with char. Closes gh-11680
This commit is contained in:
committed by
Phillip Webb
parent
2735f57b0d
commit
b19dcb13e2
@@ -253,8 +253,8 @@ public class JarWriter implements LoaderClassesWriter, AutoCloseable {
|
||||
else {
|
||||
entry.setUnixMode(UnixStat.FILE_FLAG | UnixStat.DEFAULT_FILE_PERM);
|
||||
}
|
||||
if (parent.lastIndexOf("/") != -1) {
|
||||
parent = parent.substring(0, parent.lastIndexOf("/") + 1);
|
||||
if (parent.lastIndexOf('/') != -1) {
|
||||
parent = parent.substring(0, parent.lastIndexOf('/') + 1);
|
||||
if (!parent.isEmpty()) {
|
||||
writeEntry(new JarArchiveEntry(parent), null);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user