[Typo3-dev] Bug in class.gzip_encode
4Dfx
peter.russ at 4dfx.de
Sun Sep 7 14:07:13 CEST 2003
Simon Child schrieb:
> "Peter Russ :: 4Dfx" <peter.russ at 4dfx.de> wrote in message
> news:mailman.1062812402.27205.typo3-dev at lists.netfielders.de...
>
>>Peter Russ :: 4Dfx schrieb:
>
>
>>As [BE] has also the option to work with compression in several methods
>>it might be a better a idea to fix the bug within the
>>class.gzip_encode.php. Pls find attached.
>
>
> You're converting the string 'true' to Boolean true, and then comparing as
> boolean. What is the advantage of this over simply comparing the string with
> double equals ? (Not a troll, just can't see the advantage!)
>
If you take the class only for Typo there might be no advantage. But as
you can use it also in other projects you might invoke the methode with
the variables of the correct type ie. either Boolean true or Integer
between 0 and 9. If we would just fix the "Typo" bug and compare to
string you would additionally have to compare to Boolean true otherwise
we would create a new bug ;)
So it is easier to convert the type to get it fixed for Typo3.
I hope it's clear now.
Regs. Peter.
www.ebconclub.net
More information about the TYPO3-dev
mailing list