]> source.dussan.org Git - sonarqube.git/commitdiff
When not logged, do not load favorite issue filters
authorJulien Lancelot <julien.lancelot@gmail.com>
Thu, 18 Jul 2013 06:42:05 +0000 (08:42 +0200)
committerJulien Lancelot <julien.lancelot@gmail.com>
Thu, 18 Jul 2013 06:42:05 +0000 (08:42 +0200)
sonar-server/src/main/webapp/WEB-INF/app/controllers/issues_controller.rb

index 61d477a205ccee2d5dc3f95c4e88cc2f52d2e3a5..98f965c30b6848ba57a9828c271e4992c0f60a82 100644 (file)
@@ -22,7 +22,7 @@ require 'set'
 class IssuesController < ApplicationController
 
   before_filter :init_options
-  before_filter :load_filters, :only => [:index, :search, :filter, :manage, :toggle_fav]
+  before_filter :load_fav_filters, :only => [:index, :search, :filter, :manage, :toggle_fav]
 
   PAGE_SIZE = 100
 
@@ -173,8 +173,8 @@ class IssuesController < ApplicationController
     @options_for_resolutions = Internal.issues.listResolutions().map { |s| [message('issue.resolution.' + s), s] }
   end
 
-  def load_filters
-    @favourite_filters = Internal.issues.findFavouriteIssueFiltersForCurrentUser()
+  def load_fav_filters
+    @favourite_filters = Internal.issues.findFavouriteIssueFiltersForCurrentUser() if logged_in?
   end
 
   def find_filter(id)