We now have the ability to detect legacy routes directly rather than indirectly. So let's do that.

As a side effect, this means that new-style controllers can call functions, not just classed methods. (That's still not recommended, but it will now work.)

Patch as soon as I have a nid.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Crell’s picture

Component: entity system » routing system
Status: Active » Needs review
FileSize
1.16 KB

Status: Needs review » Needs work

The last submitted patch, 2026037-legacy-check.patch, failed testing.

Crell’s picture

Status: Needs work » Needs review
FileSize
1.16 KB

Chasing HEAD. I tried 3 of the failing tests and all of them passed for me locally. I don't know why. My best guess is testbot is on 5.3 and I'm on 5.4, but I'd expect the issue to be the other way around, then.

(No interdiff; it's a one character change in a tiny patch.)

Crell’s picture

Issue tags: +WSCCI

Tagging.

dawehner’s picture

Status: Needs review » Reviewed & tested by the community

The patch looks pretty perfect. Hopefully we are able to convert all of the callbacks in a reasonable amount of time, so we can get rid of the legacy related functionality.

webchick’s picture

Status: Reviewed & tested by the community » Fixed

Actually, I love this quite a lot. Since Symfony allows whatever callable, it makes sense for us to do it too, and It's a good emergency stopgap if converting things to controllers is the last critical issue holding up RC1; we could simply script conversion of the rest to point at their callback functions.

Committed and pushed to 8.x. Thanks!

Automatically closed -- issue fixed for 2 weeks with no activity.