diff --git a/classes/Importer.php b/classes/Importer.php index 1ee4212a0149435f513efb1800b9dc24fc7fbe01..5915363d77885fdaeeec0747b16cde4e6a57f05d 100644 --- a/classes/Importer.php +++ b/classes/Importer.php @@ -127,7 +127,9 @@ class Importer{ }elseif($compType == LS."LodspeakrVisualComponent"){ $this->createViews($inputs); }else{ - Logging::log("Component '$component' (of type $compType) not supported", E_USER_WARNING); + if($conf['debug']){ + Logging::log("Component '$component' (of type $compType) not supported", E_USER_WARNING); + } } } $content .= "?>\n"; diff --git a/classes/MetaDb.php b/classes/MetaDb.php index 404a3793027548e7c597c9c6024c727cc5ab9c07..428352e023d7c7dc63f0debe5f4465421c49e6d3 100644 --- a/classes/MetaDb.php +++ b/classes/MetaDb.php @@ -35,7 +35,9 @@ class MetaDb{ $db = NULL; }catch(Exception $e){ echo "Can't write in SQLite database. Please check you have granted write permissions to <tt>meta/</tt> and <tt>meta/db.sqlite</tt>.<br/>Also you can check a list of <a href='https://github.com/alangrafu/lodspeakr/wiki/CommonErrors'>common errors</a> and how to <a href='https://github.com/alangrafu/lodspeakr/wiki/Wipe-out-the-database'>wipe out the database</a>'"; - Logging::log('Exception exec: '.$e->getMessage(), E_USER_ERROR); + if($conf['debug']){ + Logging::log('Exception exec: '.$e->getMessage(), E_USER_ERROR); + } exit(1); } return $results; diff --git a/classes/Utils.php b/classes/Utils.php index 57461792fa7d6073bd87012a988d9bcb8c18575f..517d2503a8b7ba446589477df4b734a52afbd49e 100644 --- a/classes/Utils.php +++ b/classes/Utils.php @@ -280,8 +280,10 @@ class Utils{ if($modelFile != "." && $modelFile != ".." && strpos($modelFile, ".") !== 0){ if(is_dir($modelFile)){ if(strpos('endpoint.', $modelFile) == 0){ - Logging::log("Save $modelFile for later, after all the queries in the current directory has been resolved", E_USER_NOTICE); - $subDirs[]=$modelFile; + if($conf['debug']){ + Logging::log("Save $modelFile for later, after all the queries in the current directory has been resolved", E_USER_NOTICE); + } + $subDirs[]=$modelFile; } }else{ if(preg_match('/\.query$/', $modelFile)){