[development] What is the substitude of base in hook_node_info()?

Augustin (Beginner) drupal.beginner at wechange.org
Mon Aug 14 10:15:30 UTC 2006


Hello,

There are some undocumented changes in hook_node_info():
http://drupal.org/node/64279#comment-143533

The hook returns an array. In 4.7, the array has the key 'base', which is 
replaced by the key 'module' in head.

How should the project.module  be updated?


function project_node_info() {
  return array(
    'project_project' => array('name' => t('project'), 'base' => 
'project_project'),
    'project_issue' => array('name' => t('issue'), 'base' => 
'project_issue'));
}


It defines two different node types, and the base is used to call callback 
functions, for some node types hooks like hook_access().
Thus, project_project_access() and project_issue_access() are called according 
to the node type.

How is this supposed to work in head?
Is 'module' the exact equivalent of 'base'?

A.




-- 
http://www.wechange.org/
Because we and the world need to change.
 
http://www.reuniting.info/
Intimate Relationships, peace and harmony in the couple.


More information about the development mailing list