From: Tim Starling Date: Fri, 15 Aug 2008 15:56:48 +0000 (+0000) Subject: Avoid notice when no categories are present X-Git-Tag: 1.31.0-rc.0~45891 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/ajouter.php?a=commitdiff_plain;h=213a310d097a96ab75c8134b4d1d4728e3897243;p=lhc%2Fweb%2Fwiklou.git Avoid notice when no categories are present --- diff --git a/maintenance/parserTests.inc b/maintenance/parserTests.inc index ba8349737b..01409c174b 100644 --- a/maintenance/parserTests.inc +++ b/maintenance/parserTests.inc @@ -336,7 +336,11 @@ class ParserTest { global $wgOut; $wgOut->addCategoryLinks($output->getCategories()); $cats = $wgOut->getCategoryLinks(); - $out = $this->tidy( implode( ' ', $cats['normal'] ) ); + if ( isset( $cats['normal'] ) ) { + $out = $this->tidy( implode( ' ', $cats['normal'] ) ); + } else { + $out = ''; + } } $result = $this->tidy($result);