summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2008-07-01 20:59:38 +0000
committerDries Buytaert <dries@buytaert.net>2008-07-01 20:59:38 +0000
commit31fbddc458a1054c026f0db651cc8a63639f71a9 (patch)
tree2d2f9717538d90b7d4cd830b85bd0736b6e48ce8
parent7b66734d4ea9366a84120c241a25dfcd119866f1 (diff)
downloadbrdo-31fbddc458a1054c026f0db651cc8a63639f71a9.tar.gz
brdo-31fbddc458a1054c026f0db651cc8a63639f71a9.tar.bz2
- Patch #276860 by pwolanin: removed dead code from book module. Does not affect the book module tests.
-rw-r--r--modules/book/book.admin.inc23
1 files changed, 0 insertions, 23 deletions
diff --git a/modules/book/book.admin.inc b/modules/book/book.admin.inc
index cbc5e2c97..8b5d4e6f3 100644
--- a/modules/book/book.admin.inc
+++ b/modules/book/book.admin.inc
@@ -229,26 +229,3 @@ function theme_book_admin_table($form) {
return theme('table', $header, $rows, array('id' => 'book-outline'));
}
-/**
- * Recursive helper to sort each layer of a book tree by weight.
- */
-function _book_admin_sort_tree(&$tree) {
- uasort($tree, '_book_admin_compare');
- foreach ($tree as $key => $subtree) {
- if (!empty($tree[$key]['below'])) {
- _book_admin_sort_tree($tree[$key]['below']);
- }
- }
-}
-
-/**
- * Used by uasort() in _book_admin_sort_tree() to compare items in a book tree.
- */
-function _book_admin_compare($a, $b) {
- $weight = $a['link']['weight'] - $b['link']['weight'];
- if ($weight) {
- return $weight;
- }
-
- return strncmp($a['link']['title'], $b['link']['title']);
-}