junichi11 commented on code in PR #7053:
URL: https://github.com/apache/netbeans/pull/7053#discussion_r1491851828


##########
profiler/profiler.api/src/org/netbeans/modules/profiler/api/ProjectUtilities.java:
##########
@@ -137,17 +135,9 @@ public static void 
removeOpenProjectsListener(ChangeListener listener) {
     public static Provider[] getSortedProjects(Provider[] projects) {
         List<Provider> projectsArray = Arrays.asList(projects);
 
-        Collections.sort(projectsArray,
-                new Comparator() {
-
-                    @Override
-                    public int compare(Object o1, Object o2) {
-                        Provider p1 = (Provider) o1;
-                        Provider p2 = (Provider) o2;
-
-                        return 
getDisplayName(p1).toLowerCase().compareTo(getDisplayName(p2).toLowerCase());
-                    }
-                });
+        projectsArray.sort((Object o1, Object o2) -> 
+            getDisplayName((Provider) 
o1).toLowerCase().compareTo(getDisplayName((Provider) o2).toLowerCase())

Review Comment:
   Can't use `compareToIgnoreCase`?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to