Review main Merged

63275[TASK] Mark TypeConverterException final

Alexander Schnitzler CR +2 V +2 Easy +1 −1 updated 02/22/20, 21:29

Commit message

Class \TYPO3\CMS\Form\Mvc\Property\Exception\TypeConverterException
provides a factory method fromError to instantiate new instance of
itself. It's done via new static(...) which is unsafe if the class
is not final as the implementation cannot know if constructors of
sub classes have the same method signature like itself.

One solution to this issue is to make a class final, another is to
use new self() instead of new static(). In this case, the class is
made final as this is a very specific Exception already and unlikely
to be extended.

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Issues 1

Files 1