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.
Split from #2091399: [META] Remove menu_get_object()
Only one instance which is in taxonomy_term_is_page()
.
Comment | File | Size | Author |
---|---|---|---|
#3 | menu_get_object.2095971-03.patch | 722 bytes | ekes |
#2 | menu_get_object.2095971-02.patch | 682 bytes | ekes |
Comments
Comment #1
ekes CreditAttribution: ekes commentedFrom the original issue, this one instance:
menu_get_object()
is breaking (fatal error)taxonomy_term_is_page()
if the core taxonomy/term/% page view is enabled (views.view.taxonomy_term.yml
).To reproduce, add content in terms. Enable view. Clear cache. Then
$request->attributes->get(RouteObjectInterface::ROUTE_OBJECT)->getPath();
returns NULL. Hencetaxonomy_term_is_page()
tries to accessid
on non-object$page_term
.Comment #2
ekes CreditAttribution: ekes commentedSomething as simple as attached?
Comment #3
ekes CreditAttribution: ekes commentedFollowing suggestion in irc from timplunkett.
Comment #5
ekes CreditAttribution: ekes commented#3: menu_get_object.2095971-03.patch queued for re-testing.
Comment #6
tim.plunkettLooks good to me, and was the only instance of this.
Comment #7
webchickCommitted and pushed to 8.x. Thanks!