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.
* @return string
* A \Drupal\Core\Access\AccessInterface constant value.
Well, here are several things that is not entirely correct:
- There is no class called \Drupal\Core\Access\AccessInterface
- There are certainly no constants there.
- The function does not return a string at all, but rather a \Drupal\Core\Access\AccessResultInterface
Let's go ahead and fix that! :)
Patch coming up
Comment | File | Size | Author |
---|---|---|---|
#3 | 3075404-3.patch | 3.15 KB | eiriksm |
#2 | 3075404.patch | 884 bytes | eiriksm |
Comments
Comment #2
eiriksmComment #3
eiriksmJust searched the codebase and found some more errors of the same type. Attached a patch with all of them.
Comment #4
idebr CreditAttribution: idebr at ezCompany commentedApplied the patch in #3 locally and manually checked all services tagged as
access_check
to confirm the return type in the docblock is now correct throughout Drupal Core.Comment #5
larowlanCommitted 4907fa7 and pushed to 8.8.x. Thanks!