From 6f426ddf0f25cd84cc042a4c843b75c55f322c9d Mon Sep 17 00:00:00 2001 From: David M Date: Sun, 25 Feb 2007 05:38:15 +0000 Subject: [PATCH] #8292 git-svn-id: file:///svn/phpbb/trunk@7058 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/includes/ucp/ucp_pm_compose.php | 6 ++++++ phpBB/posting.php | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/phpBB/includes/ucp/ucp_pm_compose.php b/phpBB/includes/ucp/ucp_pm_compose.php index c228e8daba..fed72402f2 100644 --- a/phpBB/includes/ucp/ucp_pm_compose.php +++ b/phpBB/includes/ucp/ucp_pm_compose.php @@ -528,6 +528,12 @@ function compose_pm($id, $mode, $action) } } + // On a refresh we do not care about message parsing errors + if (sizeof($message_parser->warn_msg) && $refresh) + { + $message_parser->warn_msg = array(); + } + if (sizeof($message_parser->warn_msg) && !($remove_u || $remove_g || $add_to || $add_bcc)) { $error[] = implode('
', $message_parser->warn_msg); diff --git a/phpBB/posting.php b/phpBB/posting.php index 247b88c63c..3515d118b3 100644 --- a/phpBB/posting.php +++ b/phpBB/posting.php @@ -408,7 +408,8 @@ if ($user->data['is_registered'] && $auth->acl_get('u_savedrafts')) $sql = 'SELECT draft_id FROM ' . DRAFTS_TABLE . ' WHERE (forum_id IN (' . $forum_id . ', 0)' . (($topic_id) ? " OR topic_id = $topic_id" : '') . ') - AND user_id = ' . $user->data['user_id'] . + AND (forum_id <> 0 AND topic_id <> 0) + AND user_id = ' . $user->data['user_id'] . (($draft_id) ? " AND draft_id <> $draft_id" : ''); $result = $db->sql_query_limit($sql, 1);