diff --git a/blocks/admin/block_admin.php b/blocks/admin/block_admin.php
index 74676b3299a..17af3a4bb42 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;
}