[TYPO3-50-general] CGL discussions (misced topics)
Bastian Waidelich
bastian at typo3.org
Mon Jun 8 15:51:46 CEST 2009
Robert Lemke wrote:
Hi Robert,
> if ($hellFreezes) throw new \F3\Hell\Exception\HelloTooColdException(...);
> Does that confuse you?
It wouldn't confuse me. But I think
if ($heavenBurns) {
throw new \F3\Heaven\Exception\HeavenTooHotException(...);
}
is ok either.. and more consistent.
and you wouldn't have to modify the nesting (=error prone) when you
wanted to add something at a later point, like:
if ($heavenBurns) {
$this->logger->log('heaven was too hot..');
throw new \F3\Heaven\Exception\HeavenTooHotException(...);
}
Bastian
More information about the TYPO3-project-5_0-general
mailing list