function social_album_preprocess_block__social_post in Open Social 10.1.x
Same name and namespace in other branches
- 10.3.x modules/social_features/social_album/social_album.module \social_album_preprocess_block__social_post()
- 10.0.x modules/social_features/social_album/social_album.module \social_album_preprocess_block__social_post()
- 10.2.x modules/social_features/social_album/social_album.module \social_album_preprocess_block__social_post()
Implements hook_preprocess_HOOK().
File
- modules/
social_features/ social_album/ social_album.module, line 88 - The Social Album module.
Code
function social_album_preprocess_block__social_post(&$variables) {
if (\Drupal::routeMatch()
->getRouteName() === 'social_album.post' && ($content = \Drupal::service('social_post.helper')
->buildCurrentUserImage())) {
$variables['content'] = [
'form' => $variables['content'],
'current_user_image' => $content,
];
}
}