mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-20 18:28:55 +00:00
Merge branch 'develop-ascraeus' into develop
* develop-ascraeus: [ticket/12344] Add core.pm_submit_before to function submit_pm
This commit is contained in:
commit
f6ae3959a0
1 changed files with 13 additions and 1 deletions
|
@ -1575,7 +1575,7 @@ function get_folder_status($folder_id, $folder)
|
||||||
*/
|
*/
|
||||||
function submit_pm($mode, $subject, &$data, $put_in_outbox = true)
|
function submit_pm($mode, $subject, &$data, $put_in_outbox = true)
|
||||||
{
|
{
|
||||||
global $db, $auth, $config, $phpEx, $template, $user, $phpbb_root_path, $phpbb_container;
|
global $db, $auth, $config, $phpEx, $template, $user, $phpbb_root_path, $phpbb_container, $phpbb_dispatcher;
|
||||||
|
|
||||||
// We do not handle erasing pms here
|
// We do not handle erasing pms here
|
||||||
if ($mode == 'delete')
|
if ($mode == 'delete')
|
||||||
|
@ -1585,6 +1585,18 @@ function submit_pm($mode, $subject, &$data, $put_in_outbox = true)
|
||||||
|
|
||||||
$current_time = time();
|
$current_time = time();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get all parts of the PM that are to be submited to the DB.
|
||||||
|
*
|
||||||
|
* @event core.submit_pm_before
|
||||||
|
* @var string mode PM Post mode - post|reply|quote|quotepost|forward|edit
|
||||||
|
* @var string subject Subject of the private message
|
||||||
|
* @var array data The whole row data of the PM.
|
||||||
|
* @since 3.1.0-b3
|
||||||
|
*/
|
||||||
|
$vars = array('mode', 'subject', 'data');
|
||||||
|
extract($phpbb_dispatcher->trigger_event('core.submit_pm_before', compact($vars)));
|
||||||
|
|
||||||
// Collect some basic information about which tables and which rows to update/insert
|
// Collect some basic information about which tables and which rows to update/insert
|
||||||
$sql_data = array();
|
$sql_data = array();
|
||||||
$root_level = 0;
|
$root_level = 0;
|
||||||
|
|
Loading…
Add table
Reference in a new issue