You are here

function template_preprocess_generated_files in Module Builder 8.3

Prepares variables for generated files form element template.

Default template: generated-files.html.twig.

File

./module_builder.module, line 39
Builds scaffolding for custom modules.

Code

function template_preprocess_generated_files(&$variables) {
  foreach (Element::children($variables['element']['filename_list']) as $filename) {
    $variables['filename_list'][$filename] = $variables['element']['filename_list'][$filename];
  }
  foreach (Element::children($variables['element']['code']) as $filename) {
    $variables['code'][$filename] = $variables['element']['code'][$filename];
  }
}