Reduce exception.

This commit is contained in:
Will Rossiter 2014-11-18 19:12:19 +13:00
parent 1e2737bc5a
commit bda0b00b18
2 changed files with 6 additions and 1 deletions

View File

@ -122,8 +122,10 @@ class DocumentationManifest {
$key = (isset($details['Key'])) ? $details['Key'] : $details['Title'];
if(!is_dir($path)) {
if($path && !is_dir($path)) {
throw new Exception($path . ' is not a valid documentation directory');
} else if(!$path) {
return;
}
$version = (isset($details['Version'])) ? $details['Version'] : '';

View File

@ -112,7 +112,10 @@ class RebuildLuceneDocsIndex extends BuildTask {
$doc->boost = $boost;
}
}
error_reporting(E_ALL ^ E_NOTICE);
$index->addDocument($doc);
if(!$quiet) {
if(Director::is_cli()) echo " * adding ". $page->getPath() ."\n";
else echo "<li>adding ". $page->getPath() ."</li>\n";