function ajax_comments_preprocess_status_messages in AJAX Comments 8
Implements template_preprocess_status_messages().
File
- ./
ajax_comments.module, line 334 - AJAX comments module file.
Code
function ajax_comments_preprocess_status_messages(&$variables) {
$request = \Drupal::request();
$route_name = RouteMatch::createFromRequest($request)
->getRouteName();
if (strpos($route_name, 'ajax_comments') !== FALSE) {
$variables['attributes']['class'][] = 'js-ajax-comments-messages';
}
}