function _absolute_messages_group_duplicates in Absolute Messages 6
Same name and namespace in other branches
- 7 absolute_messages.module \_absolute_messages_group_duplicates()
Finds all duplicate messages and groups them together.
1 call to _absolute_messages_group_duplicates()
- theme_absolute_messages in ./
absolute_messages.module - Theme function, overriding Drupal's theme_status_messages().
File
- ./
absolute_messages.module, line 209 - Module displaying system messages in colored horizontal bars on top of the page, similar to Stack Overflow / Stack Exchange network notifications.
Code
function _absolute_messages_group_duplicates($messages) {
$processed = array();
foreach (array_count_values($messages) as $message => $count) {
$processed[] = theme('absolute_messages_grouped_message', array(
'message' => $message,
'count' => $count,
));
}
return $processed;
}