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.
Miscellaneous coding style fixes:
- Changes null, true and false to upper case
- Changes
while (...) {}
(on one line) towhile (...);
- Removes a closing ?> at end of the file
- Changes
if (..) {...}
in template files toif (...): ... endif;
Cheers,
Stella
Comment | File | Size | Author |
---|---|---|---|
#3 | coding_style_misc.patch | 9.35 KB | stella |
coding_style_misc.patch | 10.78 KB | stella | |
Comments
Comment #1
agentrickardI will RTBC this if it passes the bot.
However, reading the patch suggests to me that
drupal_truncate_bytes
needs a small refactor for clarity. Thewhile
line corrected by this patch is clear as mud.Here's the full function (as patched):
I cannot tell from reading the code what that second
while
statement actually _does_.Comment #2
agentrickardAs promised.
Comment #3
stella CreditAttribution: stella commentedRe-rolled version, added in comment to clarify the while (...); line in unicode.inc. Also removed the endif; changes to the two tpl.php files - will open a separate issue for those.
Comment #4
stella CreditAttribution: stella commentedendif in template files was patched in #471206: coding style fixes - if statement in template files.
Resetting this to RTBC since testing bot passed it, and not much else has changed.
Comment #5
Dries CreditAttribution: Dries commentedCommitted to CVS HEAD. Thanks!