diff --git a/phpBB/docs/CHANGELOG.html b/phpBB/docs/CHANGELOG.html
index 06669709a5..2704013dbf 100644
--- a/phpBB/docs/CHANGELOG.html
+++ b/phpBB/docs/CHANGELOG.html
@@ -134,6 +134,7 @@
[Fix] Correctly display ACP logs options, without permission to clear logs. (Bug #24155 - Patch by leviatan21)
[Fix] Display topic icons in MCP forum view again (only prosilver).
[Fix] Properly display post status messages in topic when post is reported and unapproved (Bug #44455 - Patch by leviatan21)
+ [Fix] Loading draft removes recipients when replying to PM (Bug #38395 - Patch by nickvergessen)
[Fix] Add poster-name to moderator-log when deleting post/topic (Bug #46225 - Patch by nickvergessen)
[Fix] "Report details" link broken in MCP (Bug #46975 - Patch by nickvergessen)
[Fix] Resolve accesskey conflicts in prosilver. (Bug #44685 - Patch by bantu)
diff --git a/phpBB/includes/functions_posting.php b/phpBB/includes/functions_posting.php
index e0dc128583..18bb432769 100644
--- a/phpBB/includes/functions_posting.php
+++ b/phpBB/includes/functions_posting.php
@@ -818,7 +818,7 @@ function posting_gen_attachment_entry($attachment_data, &$filename_data, $show_a
/**
* Load Drafts
*/
-function load_drafts($topic_id = 0, $forum_id = 0, $id = 0)
+function load_drafts($topic_id = 0, $forum_id = 0, $id = 0, $pm_action = '', $msg_id = 0)
{
global $user, $db, $template, $auth;
global $phpbb_root_path, $phpEx;
@@ -911,7 +911,7 @@ function load_drafts($topic_id = 0, $forum_id = 0, $id = 0)
{
// Either display as PM draft if forum_id and topic_id are empty or if access to the forums has been denied afterwards...
$link_pm = true;
- $insert_url = append_sid("{$phpbb_root_path}ucp.$phpEx", "i=$id&mode=compose&d={$draft['draft_id']}");
+ $insert_url = append_sid("{$phpbb_root_path}ucp.$phpEx", "i=$id&mode=compose&d={$draft['draft_id']}" . (($pm_action) ? "&action=$pm_action" : '') . (($msg_id) ? "&p=$msg_id" : ''));
}
$template->assign_block_vars('draftrow', array(
diff --git a/phpBB/includes/ucp/ucp_pm_compose.php b/phpBB/includes/ucp/ucp_pm_compose.php
index 008d8d6c88..85e43dfc8c 100644
--- a/phpBB/includes/ucp/ucp_pm_compose.php
+++ b/phpBB/includes/ucp/ucp_pm_compose.php
@@ -631,7 +631,7 @@ function compose_pm($id, $mode, $action)
// Load Drafts
if ($load && $drafts)
{
- load_drafts(0, 0, $id);
+ load_drafts(0, 0, $id, $action, $msg_id);
}
if ($submit || $preview || $refresh)