function CourseObjectBook::getNodeTypes in Course 7.2
Same name and namespace in other branches
- 6 modules/course_book/course_book.classes.inc \CourseObjectBook::getNodeTypes()
- 7 modules/course_book/course_book.classes.inc \CourseObjectBook::getNodeTypes()
Return a list of valid node types.
Return value
array An array with node type machine names.
Overrides CourseObjectNode::getNodeTypes
File
- modules/
course_book/ course_book.classes.inc, line 14
Class
Code
function getNodeTypes() {
if (user_access('administer book outlines')) {
return array_keys(node_type_get_names());
}
else {
return variable_get('book_allowed_types', array(
'book',
));
}
}