summaryrefslogtreecommitdiff
path: root/inc/search.php
diff options
context:
space:
mode:
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)){