]> source.dussan.org Git - sonarqube.git/commitdiff
Sort languages in Api::Utils.languages()
authorSimon Brandhof <simon.brandhof@gmail.com>
Fri, 14 Dec 2012 17:12:15 +0000 (18:12 +0100)
committerSimon Brandhof <simon.brandhof@gmail.com>
Fri, 14 Dec 2012 17:13:21 +0000 (18:13 +0100)
sonar-server/src/main/webapp/WEB-INF/app/models/api/utils.rb
sonar-server/src/main/webapp/WEB-INF/app/views/project/profile.html.erb

index 5a96b151aa3546f358a6392a9cb286871d9c12d1..99ffe32669c1c91c8007140d0fcd2912c26187c4 100644 (file)
@@ -168,7 +168,7 @@ class Api::Utils
   end
 
   def self.languages
-    java_facade.getLanguages()
+    java_facade.getLanguages().sort_by(&:getName)
   end
 
   def self.language(key)
index ee18bc9e7df2606de4294a7720e053deb7db4992..f2cc72743ea8a14b7253222d92bf36ace44b7d2f 100644 (file)
@@ -9,7 +9,7 @@
   </thead>
   <tbody>
   <%
-     Api::Utils.languages.sort_by { |l| l.getKey() }.each do |language|
+     Api::Utils.languages.each do |language|
        selected_profile=@project.profile(language.getKey(), false)
   %>
     <tr class="<%= cycle 'even', 'odd' -%>">