|
|
|
@ -1,7 +1,7 @@
|
|
|
|
|
<?php
|
|
|
|
|
// TODO: make configurable
|
|
|
|
|
//require_once "classes/logger.php";
|
|
|
|
|
//require_once "classes/logger/sql.php";
|
|
|
|
|
require_once "classes/logger.php";
|
|
|
|
|
require_once "classes/logger/sql.php";
|
|
|
|
|
|
|
|
|
|
function ttrss_error_handler($errno, $errstr, $file, $line, $context) {
|
|
|
|
|
global $logger;
|
|
|
|
@ -37,11 +37,16 @@ function ttrss_fatal_handler() {
|
|
|
|
|
if (!$logger) $logger = new Logger_SQL();
|
|
|
|
|
|
|
|
|
|
if ($logger) {
|
|
|
|
|
$logger->log_error($errno, $errstr, $file, $line, $context);
|
|
|
|
|
if ($logger->log_error($errno, $errstr, $file, $line, $context)) {
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//register_shutdown_function('ttrss_fatal_handler');
|
|
|
|
|
//set_error_handler('ttrss_error_handler');
|
|
|
|
|
register_shutdown_function('ttrss_fatal_handler');
|
|
|
|
|
set_error_handler('ttrss_error_handler');
|
|
|
|
|
?>
|
|
|
|
|