aboutsummaryrefslogtreecommitdiff
path: root/mod/pages
diff options
context:
space:
mode:
Diffstat (limited to 'mod/pages')
-rw-r--r--mod/pages/lib/pages.php22
-rw-r--r--mod/pages/start.php1
2 files changed, 12 insertions, 11 deletions
diff --git a/mod/pages/lib/pages.php b/mod/pages/lib/pages.php
index 3f27118a6..9a9ba12e9 100644
--- a/mod/pages/lib/pages.php
+++ b/mod/pages/lib/pages.php
@@ -103,16 +103,18 @@ function pages_register_navigation_tree($container) {
'metadata_value' => $parent->getGUID(),
'limit' => 0,
));
-
- foreach ($children as $child) {
- elgg_register_menu_item('pages_nav', array(
- 'name' => $child->getGUID(),
- 'text' => $child->title,
- 'href' => $child->getURL(),
- 'parent_name' => $parent->getGUID(),
- ));
- array_push($stack, $child);
+
+ if ($children) {
+ foreach ($children as $child) {
+ elgg_register_menu_item('pages_nav', array(
+ 'name' => $child->getGUID(),
+ 'text' => $child->title,
+ 'href' => $child->getURL(),
+ 'parent_name' => $parent->getGUID(),
+ ));
+ array_push($stack, $child);
+ }
}
}
}
-} \ No newline at end of file
+}
diff --git a/mod/pages/start.php b/mod/pages/start.php
index c385131bd..6b0ad38b0 100644
--- a/mod/pages/start.php
+++ b/mod/pages/start.php
@@ -30,7 +30,6 @@ function pages_init() {
// Register some actions
$action_base = elgg_get_plugins_path() . 'pages/actions/pages';
elgg_register_action("pages/edit", "$action_base/edit.php");
- elgg_register_action("pages/editwelcome", "$action_base/editwelcome.php");
elgg_register_action("pages/delete", "$action_base/delete.php");
// Extend the main css view