|
From: Henry S. <kel...@ph...> - 2009-09-11 14:03:15
|
Author: Kellanved
Date: Fri Sep 11 14:53:56 2009
New Revision: 10136
Log:
#50985
Modified:
branches/phpBB-3_0_0/phpBB/docs/CHANGELOG.html
branches/phpBB-3_0_0/phpBB/includes/ucp/ucp_pm_viewfolder.php
branches/phpBB-3_0_0/phpBB/language/en/ucp.php
Modified: branches/phpBB-3_0_0/phpBB/docs/CHANGELOG.html
==============================================================================
*** branches/phpBB-3_0_0/phpBB/docs/CHANGELOG.html (original)
--- branches/phpBB-3_0_0/phpBB/docs/CHANGELOG.html Fri Sep 11 14:53:56 2009
***************
*** 210,215 ****
--- 210,216 ----
<li>[Fix] Do not display links to user/post search if search is disabled. (Bug #50685 - Patch by HardStyle)</li>
<li>[Fix] Fix icon alignment for forums with large descriptions in subsilver2. (Bug #50445)</li>
<li>[Fix] Correctly display underlined links placed in last line in viewtopic. (Bug #14811 - Patch by primehalo)</li>
+ <li>[Fix] Handle export of orivate messages where all recipients were deleted. (Bug #50985)</li>
<li>[Change] submit_post() now accepts force_approved_state key passed to $data to indicate new posts being approved (true) or unapproved (false).</li>
<li>[Change] Change the data format of the default file ACM to be more secure from tampering and have better performance.</li>
<li>[Change] Add index on log_time to the log table to prevent slowdown on boards with many log entries. (Bug #44665 - Patch by bantu)</li>
Modified: branches/phpBB-3_0_0/phpBB/includes/ucp/ucp_pm_viewfolder.php
==============================================================================
*** branches/phpBB-3_0_0/phpBB/includes/ucp/ucp_pm_viewfolder.php (original)
--- branches/phpBB-3_0_0/phpBB/includes/ucp/ucp_pm_viewfolder.php Fri Sep 11 14:53:56 2009
***************
*** 194,206 ****
else
{
// Build Recipient List if in outbox/sentbox
! $address = $data = array();
if ($folder_id == PRIVMSGS_OUTBOX || $folder_id == PRIVMSGS_SENTBOX)
{
foreach ($folder_info['rowset'] as $message_id => $row)
{
! $address[$message_id] = rebuild_header(array('to' => $row['to_address'], 'bcc' => $row['bcc_address']));
}
}
--- 194,208 ----
else
{
// Build Recipient List if in outbox/sentbox
!
! $address_temp = $address = $data = array();
if ($folder_id == PRIVMSGS_OUTBOX || $folder_id == PRIVMSGS_SENTBOX)
{
foreach ($folder_info['rowset'] as $message_id => $row)
{
! $address_temp[$message_id] = rebuild_header(array('to' => $row['to_address'], 'bcc' => $row['bcc_address']));
! $address[$message_id] = array();
}
}
***************
*** 224,231 ****
$_types = array('u', 'g');
foreach ($_types as $ug_type)
{
! if (isset($address[$message_id][$ug_type]) && sizeof($address[$message_id][$ug_type]))
{
if ($ug_type == 'u')
{
$sql = 'SELECT user_id as id, username as name
--- 226,237 ----
$_types = array('u', 'g');
foreach ($_types as $ug_type)
{
! if (isset($address_temp[$message_id][$ug_type]) && sizeof($address_temp[$message_id][$ug_type]))
{
+ if (!isset($address[$message_id][$ug_type]))
+ {
+ $address[$message_id][$ug_type] = array();
+ }
if ($ug_type == 'u')
{
$sql = 'SELECT user_id as id, username as name
***************
*** 238,258 ****
FROM ' . GROUPS_TABLE . '
WHERE ';
}
! $sql .= $db->sql_in_set(($ug_type == 'u') ? 'user_id' : 'group_id', array_map('intval', array_keys($address[$message_id][$ug_type])));
$result = $db->sql_query($sql);
while ($info_row = $db->sql_fetchrow($result))
{
! $address[$message_id][$ug_type][$address[$message_id][$ug_type][$info_row['id']]][] = $info_row['name'];
! unset($address[$message_id][$ug_type][$info_row['id']]);
}
$db->sql_freeresult($result);
}
}
! decode_message($message_row['message_text'], $message_row['bbcode_uid']);
$data[] = array(
'subject' => censor_text($row['message_subject']),
'sender' => $row['username'],
--- 244,274 ----
FROM ' . GROUPS_TABLE . '
WHERE ';
}
! $sql .= $db->sql_in_set(($ug_type == 'u') ? 'user_id' : 'group_id', array_map('intval', array_keys($address_temp[$message_id][$ug_type])));
$result = $db->sql_query($sql);
while ($info_row = $db->sql_fetchrow($result))
{
! $address[$message_id][$ug_type][$address_temp[$message_id][$ug_type][$info_row['id']]][] = $info_row['name'];
! unset($address_temp[$message_id][$ug_type][$info_row['id']]);
}
$db->sql_freeresult($result);
}
}
! // There is the chance that all recipients of the message got deleted. To avoid creating
! // exports without recipients, we add a bogus "undisclosed recipient".
! if (!(isset($address[$message_id]['g']) && sizeof($address[$message_id]['g'])) &&
! !(isset($address[$message_id]['u']) && sizeof($address[$message_id]['u'])))
! {
! $address[$message_id]['u'] = array();
! $address[$message_id]['u']['to'] = array();
! $address[$message_id]['u']['to'][] = $user->lang['UNDISCLOSED_RECIPIENT'];
! }
+ decode_message($message_row['message_text'], $message_row['bbcode_uid']);
+
$data[] = array(
'subject' => censor_text($row['message_subject']),
'sender' => $row['username'],
Modified: branches/phpBB-3_0_0/phpBB/language/en/ucp.php
==============================================================================
*** branches/phpBB-3_0_0/phpBB/language/en/ucp.php (original)
--- branches/phpBB-3_0_0/phpBB/language/en/ucp.php Fri Sep 11 14:53:56 2009
***************
*** 460,465 ****
--- 460,466 ----
'UCP_ZEBRA' => 'Friends & Foes',
'UCP_ZEBRA_FOES' => 'Manage foes',
'UCP_ZEBRA_FRIENDS' => 'Manage friends',
+ 'UNDISCLOSED_RECIPIENT' => 'Undiclosed Recipient',
'UNKNOWN_FOLDER' => 'Unknown folder',
'UNWATCH_MARKED' => 'Unwatch marked',
'UPLOAD_AVATAR_FILE' => 'Upload from your machine',
|