1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-03 09:49:28 +02:00
This commit is contained in:
Daniel Neto 2024-11-06 11:01:48 -03:00
parent ff1286f365
commit 696393bd86
2 changed files with 4 additions and 4 deletions

View file

@ -7,7 +7,7 @@ error_reporting(E_ALL);
if (php_sapi_name() !== 'cli') {
die('Command Line only');
}
$global['printLogs'] = 1;
// Example usage
$filePath = Video::getStoragePath() . 'mysqldump-' . date('YmdHis') . '.sql';
$extraOptions = []; // You can add custom options here if needed

View file

@ -89,9 +89,9 @@ function _error_log($message, $type = 0, $doNotRepeat = false)
if (!is_string($message)) {
$message = json_encode($message);
}
if (isSchedulerRun() || !empty($global['printLogs'])) {
//echo $message . PHP_EOL;
//return false;
if (!empty($global['printLogs'])) {
echo $message . PHP_EOL;
return false;
}
if (empty($doNotRepeat)) {
// do not log it too many times when you are using HLS format, other wise it will fill the log file with the same error