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.
Fix are included/attached.
Comment | File | Size | Author |
---|---|---|---|
#4 | install.inc_.patch | 980 bytes | quiptime |
install.inc_.patch | 798 bytes | quiptime | |
Comments
Comment #1
aspilicious CreditAttribution: aspilicious commentedComment #2
jpmckinney CreditAttribution: jpmckinney commentedThis will set $requirement['title'] to the empty string whether it was already set or not, and I doubt $requirement['title'] will always be unset. How do you reproduce this error?
Comment #3
dawehnerThis would mean:
Has never $requirement['title'] which is senseless
Comment #4
quiptime CreditAttribution: quiptime commentedBetter solution for missing title.
Comment #5
dawehnerI would use isset, because the title "0" is a valid title, but its a boolean false.
Comment #6
David_Rothstein CreditAttribution: David_Rothstein commentedI don't see how this can possibly be a critical bug, or how it's necessarily even a bug in this function at all? As documented in http://api.drupal.org/api/function/hook_requirements/7, 'title' is always supposed to be returned, so this is occurring due to a bug in someone's implementation of this hook, not the code here.
Now what I also don't understand is the existing behavior of the function :) Why is there a drupal_set_message() in an API function like this at all (seems like that should generally be up to the caller), and why in the world does it try to assume that all error messages returned by hook_requirements() make any sense when printed out in the format "Currently using !item !version..."???
Comment #7
David_Rothstein CreditAttribution: David_Rothstein commentedHm, looking a little closer, I guess it's pseudo-documented in the hook that at install time, it's only supposed to return things like library version numbers and such... but it's still pretty weird.
I guess that's not for us to change here though. In this issue, let's just figure out where the hook implementation is that doesn't define a 'title', and fix the bug by defining one there.
Comment #8
jpmckinney CreditAttribution: jpmckinney commentedLooks like everything in core defines a title. The issue creator should report which modules they have installed.
Comment #9
jpmckinney CreditAttribution: jpmckinney commented