Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / vendor / chi-teck / drupal-code-generator / templates / d7 / hook / field_extra_fields_alter.twig
1 /**
2  * Implements hook_field_extra_fields_alter().
3  */
4 function {{ machine_name }}_field_extra_fields_alter(&$info) {
5   // Force node title to always be at the top of the list by default.
6   foreach (node_type_get_types() as $bundle) {
7     if (isset($info['node'][$bundle->type]['form']['title'])) {
8       $info['node'][$bundle->type]['form']['title']['weight'] = -20;
9     }
10   }
11 }