diff --git a/core/modules/node/lib/Drupal/node/Plugin/Core/Entity/NodeType.php b/core/modules/node/lib/Drupal/node/Plugin/Core/Entity/NodeType.php index f5a892d..9329e81 100644 --- a/core/modules/node/lib/Drupal/node/Plugin/Core/Entity/NodeType.php +++ b/core/modules/node/lib/Drupal/node/Plugin/Core/Entity/NodeType.php @@ -178,7 +178,6 @@ public function postSave(EntityStorageControllerInterface $storage_controller, $ // Unless disabled, automatically create a Body field for new node types. if ($this->get('create_body')) { - debug('create'); $label = $this->get('create_body_label'); node_add_body_field($this, $label); } diff --git a/core/modules/node/node.module b/core/modules/node/node.module index e1959c5..05011d9 100644 --- a/core/modules/node/node.module +++ b/core/modules/node/node.module @@ -1286,6 +1286,8 @@ function node_menu() { ); $items['admin/structure/types/manage/%node_type'] = array( 'title' => 'Edit content type', + 'title callback' => 'node_type_page_title', + 'title arguments' => array(4), 'route_name' => 'node_type_edit', ); $items['admin/structure/types/manage/%node_type/edit'] = array( @@ -1397,6 +1399,22 @@ function node_menu_local_tasks(&$data, $router_item, $root_path) { } /** + * Title callback: Provides the title for a node type edit form. + * + * @param string $type_name + * The machine name of the node type. + * + * @return string + * An unsanitized string that is the title of the node type edit form. + * + * @see node_menu() + */ +function node_type_page_title($type_name) { + $type = entity_load('node_type', $type_name); + return $type->label(); +} + +/** * Title callback: Displays the node's title. * * @param \Drupal\Core\Entity\EntityInterface $node