Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
foreach (module_implements('watchdog', TRUE) as $module) {
module_invoke($module, 'watchdog', $log_message);
}
The TRUE parameter to module_implements() makes it return the modules ordered by name. This applies to both Drupal 7 and Drupal 6.
Comment | File | Size | Author |
---|---|---|---|
#4 | 521370-watchdog_by_weight-d6.patch | 647 bytes | andypost |
#2 | watchdog_by_weight.patch | 598 bytes | marcingy |
Comments
Comment #1
marcingy CreditAttribution: marcingy commentedPatch to invoke watchdog by weight rather by name. Other than in help system which makes sense this is an exception.
Comment #2
marcingy CreditAttribution: marcingy commentedMissing patch
Comment #3
Dries CreditAttribution: Dries commentedCommitted to CVS HEAD. Thanks.
Comment #4
andypostSame for D6
Comment #5
dawehnerLooks fine
Comment #6
Gábor HojtsyThis was committed in [63881] where I found no mention of thought given into the specifics of why would this be ordered by name and not weight. Also I do not expect existing modules to be dependent on the by name ordering as by weight is the norm. So committed.