Merge branch 'MDL-67338' of git://github.com/paulholden/moodle

This commit is contained in:
Eloy Lafuente (stronk7) 2021-07-15 00:33:57 +02:00
commit a0ac76505b
4 changed files with 20 additions and 7 deletions

View File

@ -151,6 +151,7 @@ $string['on'] = 'On';
$string['online'] = 'Online';
$string['otherparticipants'] = 'Other participants';
$string['outputnotavailable'] = 'Not available';
$string['page-message-x'] = 'Any message pages';
$string['participants'] = 'Participants';
$string['pendingcontactrequests'] = 'There are {$a} pending contact requests';
$string['permitted'] = 'Permitted';

View File

@ -2338,13 +2338,6 @@ function message_mark_messages_read() {
'\core_message\api::mark_all_messages_as_read() instead.');
}
/**
* @deprecated since Moodle 3.2
*/
function message_page_type_list() {
throw new coding_exception('message_page_type_list() can not be used anymore.');
}
/**
* @deprecated since Moodle 3.2
*/

View File

@ -530,6 +530,20 @@ function translate_message_default_setting($plugindefault, $processorname) {
return array($permitted, $loggedin, $loggedoff);
}
/**
* Return a list of page types
*
* @param string $pagetype current page type
* @param context|null $parentcontext Block's parent context
* @param context|null $currentcontext Current context of block
* @return array
*/
function message_page_type_list(string $pagetype, ?context $parentcontext, ?context $currentcontext): array {
return [
'message-*' => get_string('page-message-x', 'message'),
];
}
/**
* Get messages sent or/and received by the specified users.
* Please note that this function return deleted messages too. Besides, only individual conversation messages

View File

@ -1,6 +1,11 @@
This files describes API changes in /message/ messaging system,
information provided here is intended especially for developers.
=== 3.11.2 ===
* The `message_page_type_list` method was previouly deprecated, however it was still
used so has been recreated in message/lib.php
=== 3.10 ===
* The following methods have been deprecated and should not be used any more: