Skip memberships query for anonymous user.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5458 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
910d85be47
commit
5beef16378
|
@ -223,6 +223,7 @@ module ApplicationHelper
|
|||
|
||||
# Renders the project quick-jump box
|
||||
def render_project_jump_box
|
||||
return unless User.current.logged?
|
||||
projects = User.current.memberships.collect(&:project).compact.uniq
|
||||
if projects.any?
|
||||
s = '<select onchange="if (this.value != \'\') { window.location = this.value; }">' +
|
||||
|
|
Loading…
Reference in New Issue