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.
Update hooks are an exception to the coding guideline that says the docblock should say which hook is implemented (see https://www.drupal.org/node/1354#updateN).
These use a different syntax, because the documentation summary (first line) is displayed to someone running update.php to tell them which updates need to run. So they are documented like this: [...]
This also means the description should be just a single line, which is nog always the case (Drush updb will actually show more than the first line, but update.php will not).
Comment | File | Size | Author |
---|---|---|---|
#2 | advagg-clean_update_docblocks-2844478-2-d7.patch | 9.54 KB | eelkeblok |
Comments
Comment #2
eelkeblokHere's a patch to clean this up. In some instances, the "Implements.." line was below the first line, which would be OK for update.php (and I can see the appeal of adding this), but at the end of the day it is against the comment guideline linked in the issue summary. Also, like I said, drush updb will show these. So, I removed those too.
Comment #3
jimmyko CreditAttribution: jimmyko as a volunteer commentedI second this change. It looks fine to me.
Comment #5
mikeytown2 CreditAttribution: mikeytown2 commentedThanks for the patch and the review! Patch has been committed.