diff --git a/www/controllers/Repo/Mirror/Mirror.php b/www/controllers/Repo/Mirror/Mirror.php index c2e46a0e..3d5334c8 100644 --- a/www/controllers/Repo/Mirror/Mirror.php +++ b/www/controllers/Repo/Mirror/Mirror.php @@ -199,15 +199,15 @@ public function download(string $url, string $savePath, int $retries = 0) */ if ($currentRetry != $retries) { $currentRetry++; - $this->logWarning('Curl error (' . curl_errno($this->curlHandle) . '): ' . curl_error($this->curlHandle)); - $this->logNote('Retrying (' . $currentRetry . '/' . $retries . ') ...'); + $this->taskLogSubStepController->output('Curl error (' . curl_errno($this->curlHandle) . '): ' . curl_error($this->curlHandle), 'warning'); + $this->taskLogSubStepController->output('Retrying (' . $currentRetry . '/' . $retries . ') ...', 'note'); continue; } /** * If curl has failed (meaning a curl param might be invalid or timeout has been reached) */ - $this->logError('Curl error (' . curl_errno($this->curlHandle) . '): ' . curl_error($this->curlHandle), 'Download error'); + throw new Exception('Curl error (' . curl_errno($this->curlHandle) . '): ' . curl_error($this->curlHandle)); curl_close($this->curlHandle); fclose($localFile); @@ -223,9 +223,9 @@ public function download(string $url, string $savePath, int $retries = 0) * If return code is 404 */ if ($status["http_code"] == '404') { - $this->logOutput('File not found (404)' . PHP_EOL); + $this->taskLogSubStepController->output('File not found (404)', 'error'); } else { - $this->logOutput('File could not be downloaded (http return code is: ' . $status["http_code"] . ')' . PHP_EOL); + $this->taskLogSubStepController->output('File could not be downloaded (http return code is: ' . $status["http_code"] . ')', 'error'); } curl_close($this->curlHandle); diff --git a/www/controllers/Service/ScheduledTask.php b/www/controllers/Service/ScheduledTask.php index ce10fb89..3bb9bcac 100644 --- a/www/controllers/Service/ScheduledTask.php +++ b/www/controllers/Service/ScheduledTask.php @@ -29,7 +29,6 @@ public function execute() * Quit if there was an error while loading general settings */ if (defined('__LOAD_GENERAL_ERROR') and __LOAD_GENERAL_ERROR > 0) { - // $this->logController->log('error', 'Service', 'Cannot execute scheduled task(s): some general settings are not defined.'); return; } @@ -173,7 +172,6 @@ public function sendReminders() * Quit if there was an error while loading general settings */ if (defined('__LOAD_GENERAL_ERROR') and __LOAD_GENERAL_ERROR > 0) { - // $this->logController->log('error', 'Service', 'Cannot execute scheduled task(s): some general settings are not defined.'); return; } diff --git a/www/public/assets/favicon.ico b/www/public/assets/favicon.ico index b10b007f..8d1d1185 100644 Binary files a/www/public/assets/favicon.ico and b/www/public/assets/favicon.ico differ diff --git a/www/version b/www/version index 68289521..d78433cb 100644 --- a/www/version +++ b/www/version @@ -1 +1 @@ -4.15.1 \ No newline at end of file +4.15.2 \ No newline at end of file diff --git a/www/views/includes/containers/tasks/log/substep.inc.php b/www/views/includes/containers/tasks/log/substep.inc.php index 9a1fa2b9..3a886754 100644 --- a/www/views/includes/containers/tasks/log/substep.inc.php +++ b/www/views/includes/containers/tasks/log/substep.inc.php @@ -37,20 +37,16 @@ $type = $outputDetails['type']; $message = $outputDetails['message']; - if ($type == 'info') { - echo '

' . $message . '

'; - } - - if ($type == 'warning') { - echo '

' . $message . '

'; - } - - if ($type == 'error') { + if ($type == 'note') { + echo '

' . $message . '

'; + } else if ($type == 'warning') { + echo '

' . $message . '

'; + } else if ($type == 'error') { echo '

' . $message . '

'; - } - - if ($type == 'pre') { + } else if ($type == 'pre') { echo '
' . $message . '
'; + } else { + echo '

' . $message . '

'; } } }