summaryrefslogtreecommitdiff
path: root/inc/search.php
diff options
context:
space:
mode:
authorGuillaume Turri <guillaume.turri@gmail.com>2013-01-10 22:55:43 +0100
committerGuillaume Turri <guillaume.turri@gmail.com>2013-01-10 23:03:29 +0100
commit8451f4ad87cd104e80eb42532adebd7b2882e62e (patch)
tree8d9e71da50e5c300d973e9d5b0baefc4a8a2ac42 /inc/search.php
parentc647387e09a52c1a67a72b8923ca4de06f8555cf (diff)
downloadrpg-8451f4ad87cd104e80eb42532adebd7b2882e62e.tar.gz
rpg-8451f4ad87cd104e80eb42532adebd7b2882e62e.tar.bz2
If depth option is set to 0, we should recurse forever
At least if we want to be consistent with search_universal
Diffstat (limited to 'inc/search.php')
-rw-r--r--inc/search.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/inc/search.php b/inc/search.php
index e18777063..53bd240e8 100644
--- a/inc/search.php
+++ b/inc/search.php
@@ -247,7 +247,7 @@ function search_pagename(&$data,$base,$file,$type,$lvl,$opts){
* @author Andreas Gohr <andi@splitbrain.org>
*/
function search_allpages(&$data,$base,$file,$type,$lvl,$opts){
- if(isset($opts['depth'])){
+ if(isset($opts['depth']) && $opts['depth']){
$parts = explode('/',ltrim($file,'/'));
if(($type == 'd' && count($parts) > $opts['depth'])
|| ($type != 'd' && count($parts) > $opts['depth'] + 1)){