Merge pull request #12509 from frederic34/patch-7
do not evaluate count at each iteration
This commit is contained in:
commit
65f9d3e8f1
@ -1136,7 +1136,8 @@ class EmailCollector extends CommonObject
|
|||||||
$elements = imap_mime_header_decode($overview[0]->subject);
|
$elements = imap_mime_header_decode($overview[0]->subject);
|
||||||
$newstring = '';
|
$newstring = '';
|
||||||
if (! empty($elements)) {
|
if (! empty($elements)) {
|
||||||
for ($i = 0; $i < count($elements); $i++) {
|
$num = count($elements);
|
||||||
|
for ($i = 0; $i < $num; $i++) {
|
||||||
$newstring .= ($newstring ? ' ' : '').$elements[$i]->text;
|
$newstring .= ($newstring ? ' ' : '').$elements[$i]->text;
|
||||||
}
|
}
|
||||||
$overview[0]->subject = $newstring;
|
$overview[0]->subject = $newstring;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user