MDL-74169 core_message: Hide preferences link when permissions lacking

This commit is contained in:
Frédéric Massart
2022-03-21 18:38:05 +08:00
parent bb864ee2e1
commit 7eb557e695
4 changed files with 12 additions and 6 deletions
+1
View File
@@ -626,6 +626,7 @@ class helper {
'isdrawer' => $isdrawer,
'showemojipicker' => !empty($CFG->allowemojipicker),
'messagemaxlength' => api::MESSAGE_MAX_LENGTH,
'caneditownmessageprofile' => has_capability('moodle/user:editownmessageprofile', \context_system::instance())
];
if ($sendtouser || $conversationid) {