Re: Mail/mime.php changes
| From: | Tomas V.V.Cox | Date: | Sun, 16 Sep 2001 18:19:24 +0000 |
| Subject: | Re: Mail/mime.php changes | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-1955@lists.php.net to get a copy of this message | ||
Jon Parise wrote:
>
>
> > if (!isset($this->_txtbody))
> > $this->_txtbody = 'No text version was supplied';
> >
>
> Please wrap single statements like this in braces.
>
> You might want to change that !isset() test to an empty() test,
> too.
That could sound strange, but if my email only have the char "0" in the
body? Don't forget that there are automated systems that could transfer
data by e-mail. That's applied also for e-mail with only attachments.
>
> Also, the majority of the PEAR code uses 'true' and 'false'
> (lowercase). I'm not sure if we should make that a style
> standard, but it might be good to keep that consistent. There's
> no functional difference, of course.
>
+1 to standarize special vars casing (CONSTANTS, true, false, null,
"ERROR_CODES", ...).
Tomas V.V.Cox