mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 00:12:56 +02:00
Merge branch 'MDL-56411-master' of git://github.com/ryanwyllie/moodle
This commit is contained in:
commit
0998896e9e
@ -85,10 +85,8 @@ class message_area implements templatable, renderable {
|
||||
$data->userid = $this->userid;
|
||||
$contacts = new contacts($this->otheruserid, $this->contacts);
|
||||
$data->contacts = $contacts->export_for_template($output);
|
||||
if ($this->messages) {
|
||||
$messages = new messages($this->userid, $this->otheruserid, $this->messages);
|
||||
$data->messages = $messages->export_for_template($output);
|
||||
}
|
||||
$messages = new messages($this->userid, $this->otheruserid, $this->messages);
|
||||
$data->messages = $messages->export_for_template($output);
|
||||
$data->isconversation = true;
|
||||
$data->requestedconversation = $this->requestedconversation;
|
||||
|
||||
|
@ -117,7 +117,7 @@ if (!$user2realuser) {
|
||||
|
||||
// Mark the conversation as read.
|
||||
if (!empty($user2->id)) {
|
||||
if ($currentuser) {
|
||||
if ($currentuser && isset($conversations[$user2->id])) {
|
||||
// Mark the conversation we are loading as read.
|
||||
\core_message\api::mark_all_read_for_user($user1->id, $user2->id);
|
||||
// Ensure the UI knows it's read as well.
|
||||
|
Loading…
x
Reference in New Issue
Block a user