replaced trigger_error calls by Logger methods

This commit is contained in:
Steffen Schröder
2014-08-03 13:29:54 +02:00
parent 53ccd70b45
commit c246568f95
9 changed files with 33 additions and 30 deletions

View File

@ -47,11 +47,11 @@ abstract class Logger {
public static function getLogsFolder() {
$logsFolder = ManiaControlDir . 'logs' . DIRECTORY_SEPARATOR;
if (!is_dir($logsFolder) && !mkdir($logsFolder)) {
trigger_error("Couldn't create the logs folder!");
self::logError("Couldn't create the logs folder!");
return false;
}
if (!is_writeable($logsFolder)) {
trigger_error("ManiaControl doesn't have the necessary write rights for the logs folder!");
self::logError("ManiaControl doesn't have the necessary write rights for the logs folder!");
return false;
}
return $logsFolder;