]> git.openstreetmap.org Git - rails.git/blobdiff - app/helpers/issues_helper.rb
don't check authorization everywhere
[rails.git] / app / helpers / issues_helper.rb
index 4dc1637de2cc00bb296570268eff97e22a85bd8e..f9a84ba7dd979bdc71fca2955f4eeafa6eb1f28d 100644 (file)
@@ -26,7 +26,7 @@ module IssuesHelper
   end
 
   def open_issues_count
-    count = Issue.open.limit(100).size
+    count = Issue.visible_to(current_user).open.limit(100).size
     if count > 99
       content_tag(:span, "99+", :class => "count-number")
     elsif count > 0