From d927c5b4ef4d082516927b8401e36586ad9c7c0b Mon Sep 17 00:00:00 2001 From: skodak Date: Thu, 24 Jul 2008 23:14:58 +0000 Subject: [PATCH] MDL-15821 do not show profile link in admin block if using guest account; merged from MOODLE_19_STABLE --- blocks/admin/block_admin.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/blocks/admin/block_admin.php b/blocks/admin/block_admin.php index 6a228a21d3..5f3b07240c 100644 --- a/blocks/admin/block_admin.php +++ b/blocks/admin/block_admin.php @@ -217,9 +217,11 @@ class block_admin extends block_list { } } - /// Link to the user own profile - $this->content->items[]=''.get_string('profile').''; - $this->content->icons[]=''; + /// Link to the user own profile (except guests) + if (!isguestuser() and isloggedin()) { + $this->content->items[]=''.get_string('profile').''; + $this->content->icons[]=''; + } return $this->content; } -- 2.39.5