mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-06 16:45:58 +00:00
Minor refactorings either for performance or readability (#4845)
Co-authored-by: Oleg Nenashev <o.v.nenashev@gmail.com>
This commit is contained in:
1 parent
859f01f5ad
commit
463cd113ba
12 files changed
+23
-19
No files matched your search
@@ -2196,11 +2196,7 @@ public class Functions {
|
||||
|
||||
public static ArrayList<CLICommand> getCLICommands() {
|
||||
ArrayList<CLICommand> all = new ArrayList<>(CLICommand.all());
|
||||
Collections.sort(all, new Comparator<CLICommand>() {
|
||||
public int compare(CLICommand cliCommand, CLICommand cliCommand1) {
|
||||
return cliCommand.getName().compareTo(cliCommand1.getName());
|
||||
}
|
||||
});
|
||||
all.sort(Comparator.comparing(CLICommand::getName));
|
||||
return all;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user