-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
[EMAIL PROTECTED] writes:
>make the decoded/rendered body part functions a bit more efficient and
>streamlined.
>
>+ # put a blank line between parts ...
>+ $text .= "\n" if ( $text );
>+
> my($type, $rnd) = $p->rendered(); # decode this part
> if ( defined $rnd ) {
> # Only text/* types are rendered ...
>- $text .= $text ? "\n$rnd" : $rnd;
>+ $text .= $rnd;
>
> # TVD - if there are multiple parts, what should we do?
> # right now, just use the last one ...
> $self->{html} = $p->{html_results} if ( $type eq 'text/html' );
> }
> else {
>- $text .= $text ? "\n".$p->decode() : $p->decode();
>+ $text .= $p->decode();
> }
BTW using push() and join() is generally more efficient than using .= .
But profiling is the sure-fire way to check ;)
- --j.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
Comment: Exmh CVS
iD8DBQFAS+k9QTcbUG5Y7woRApF9AKDGX7X12VMFAW28ZBazI8UnQqH9NgCfZ1eL
goPOhM95dpqcdfWJ3o2h61U=
=E9jQ
-----END PGP SIGNATURE-----