mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-31 05:50:42 +02:00
[ticket/14168] No longer use deprecated functions in core files
PHPBB3-14168
This commit is contained in:
@@ -1153,12 +1153,10 @@ function delete_pm($user_id, $msg_ids, $folder_id)
|
||||
if (sizeof($delete_ids))
|
||||
{
|
||||
// Check if there are any attachments we need to remove
|
||||
if (!function_exists('delete_attachments'))
|
||||
{
|
||||
include($phpbb_root_path . 'includes/functions_admin.' . $phpEx);
|
||||
}
|
||||
|
||||
delete_attachments('message', $delete_ids, false);
|
||||
/** @var \phpbb\attachment\delete $attachment_delete */
|
||||
$attachment_delete = $phpbb_container->get('attachment.delete');
|
||||
$attachment_delete->delete('message', $delete_ids, false);
|
||||
unset($attachment_delete);
|
||||
|
||||
$sql = 'DELETE FROM ' . PRIVMSGS_TABLE . '
|
||||
WHERE ' . $db->sql_in_set('msg_id', $delete_ids);
|
||||
@@ -1363,12 +1361,10 @@ function phpbb_delete_users_pms($user_ids)
|
||||
if (!empty($delete_ids))
|
||||
{
|
||||
// Check if there are any attachments we need to remove
|
||||
if (!function_exists('delete_attachments'))
|
||||
{
|
||||
include($phpbb_root_path . 'includes/functions_admin.' . $phpEx);
|
||||
}
|
||||
|
||||
delete_attachments('message', $delete_ids, false);
|
||||
/** @var \phpbb\attachment\delete $attachment_delete */
|
||||
$attachment_delete = $phpbb_container->get('attachment.delete');
|
||||
$attachment_delete->delete('message', $delete_ids, false);
|
||||
unset($attachment_delete);
|
||||
|
||||
$sql = 'DELETE FROM ' . PRIVMSGS_TABLE . '
|
||||
WHERE ' . $db->sql_in_set('msg_id', $delete_ids);
|
||||
|
Reference in New Issue
Block a user