function vud_preprocess in Vote Up/Down 8
Implements hook_preprocess().
File
- ./
vud.module, line 38 - Implements the core voting module on top of Voting API.
Code
function vud_preprocess(&$variables, $hook) {
$module_handler = \Drupal::service('module_handler');
$module_path = $module_handler
->getModule('vud')
->getPath();
$variables['#attached']['drupalSettings']['basePath'] = $module_path;
}