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
|
# Renders the project quick-jump box
|
||||||
def render_project_jump_box
|
def render_project_jump_box
|
||||||
|
return unless User.current.logged?
|
||||||
projects = User.current.memberships.collect(&:project).compact.uniq
|
projects = User.current.memberships.collect(&:project).compact.uniq
|
||||||
if projects.any?
|
if projects.any?
|
||||||
s = '<select onchange="if (this.value != \'\') { window.location = this.value; }">' +
|
s = '<select onchange="if (this.value != \'\') { window.location = this.value; }">' +
|
||||||
|
Loading…
x
Reference in New Issue
Block a user