[TYPO3-core] RFC: #1527: t3lib_svbase: Method init returns wrong value
Francois Suter
fsuter at cobweb.ch
Sun Feb 1 13:05:17 CET 2009
Hi Stefano,
> Problem:
> The method t3lib_svbase::init() should, according to inline documentation
> and usage in tslib_div::makeInstanceService() return a boolean value.
>
> In case of an error the method returns the last error code instead of
> boolean false. Using this default implementation as template results in
> always signaling a service to be available.
I've done a lot of investigating services recently and I would be a bit
careful about this patch. I don't have the time to look at it in detail
now, but I will as soon as I can. I agree that the logic of returning an
error code rather than false is flawed (but this piece of code was
written in a time before exceptions). However I would like to check at
least what happens with services within the core (that will be auth
services) and make sure that changing this return value doesn't break
anything (I'll check in my own pieces of code too). Have you already
checked this?
Cheers
--
Francois Suter
Cobweb Development Sarl - http://www.cobweb.ch
More information about the TYPO3-team-core
mailing list