Commit e14c3aa6 authored by Dries's avatar Dries
Browse files

- Patch #79498 by Eaton: fixed editing comments and nodes.

parent 49481f68
......@@ -136,8 +136,8 @@ function comment_menu($may_cache) {
$access = user_access('post comments');
$items[] = array('path' => 'comment/edit', 'title' => t('edit comment'),
'callback' => 'drupal_get_form',
'callback arguments' => array('comment_edit'), 'access' => $access, 'type' => MENU_CALLBACK);
'callback' => 'comment_edit',
'access' => $access, 'type' => MENU_CALLBACK);
}
else {
if (arg(0) == 'comment' && arg(1) == 'reply' && is_numeric(arg(2))) {
......
......@@ -1048,12 +1048,13 @@ function node_menu($may_cache) {
'callback arguments' => array('node_type_form'),
'type' => MENU_LOCAL_TASK,
);
$items[] = array('path' => 'node', 'title' => t('content'),
$items[] = array('path' => 'node',
'title' => t('content'),
'callback' => 'node_page_default',
'access' => user_access('access content'),
'type' => MENU_MODIFIABLE_BY_ADMIN);
$items[] = array('path' => 'node/add', 'title' => t('create content'),
$items[] = array('path' => 'node/add',
'title' => t('create content'),
'callback' => 'node_add',
'access' => user_access('access content'),
'type' => MENU_ITEM_GROUPING,
......@@ -1092,8 +1093,8 @@ function node_menu($may_cache) {
'type' => MENU_DEFAULT_LOCAL_TASK,
'weight' => -10);
$items[] = array('path' => 'node/'. arg(1) .'/edit', 'title' => t('edit'),
'callback' => 'drupal_get_form',
'callback arguments' => array('node_page_edit', $node),
'callback' => 'node_page_edit',
'callback arguments' => array($node),
'access' => node_access('update', $node),
'weight' => 1,
'type' => MENU_LOCAL_TASK);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment