Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Just saw that constructor in file /core/lib/Drupal/Component/Bridge/ZfExtensionManagerSfContainer.php has return statement. Constructor shouldn't have a return statement.
Comment | File | Size | Author |
---|---|---|---|
#2 | drupal-no-return-in-constructor-2858081-2.patch | 633 bytes | gaurav.kapoor |
Comments
Comment #2
gaurav.kapoor CreditAttribution: gaurav.kapoor at OpenSense Labs commentedComment #3
dawehnerFair point :)
Comment #4
alexpottThe only other instance of a constructor returning a value in core is \Drupal\Core\Archiver\ArchiveTar::__construct() - and that's not really 100% Drupal code and it is ancient and the returns are unreachable so... let's ignore that.
We could consider adding a check to the coder project for this but consider that there is only 1 case in core that is probably unnecessary.
Committed and pushed 37500c9 to 8.4.x and 4652263 to 8.3.x. Thanks!
Comment #8
gaurav.kapoor CreditAttribution: gaurav.kapoor at OpenSense Labs commented.
Comment #9
gaurav.kapoor CreditAttribution: gaurav.kapoor at OpenSense Labs commentedoops my bad.