diff --git a/libraries/src/Console/UpdateCoreCommand.php b/libraries/src/Console/UpdateCoreCommand.php index ca9132d8edad4..db8f0d5b0db29 100644 --- a/libraries/src/Console/UpdateCoreCommand.php +++ b/libraries/src/Console/UpdateCoreCommand.php @@ -255,7 +255,7 @@ public function doExecute(InputInterface $input, OutputInterface $output): int protected function configure(): void { $help = "%command.name% is used to update Joomla - \nUsage: php %command.full_name%"; + \nUsage: php %command.full_name%"; $this->setDescription('Update Joomla'); $this->setHelp($help); @@ -332,9 +332,15 @@ private function updateJoomlaCore($updatemodel): bool $this->progressBar->advance(); } + Log::add(Text::_('COM_JOOMLAUPDATE_UPDATE_LOG_CLEANUP'), Log::INFO, 'Update'); InstallerHelper::cleanupInstall($package['file'], $package['extractdir']); $updatemodel->purge(); + Log::add( + Text::sprintf('COM_JOOMLAUPDATE_UPDATE_LOG_COMPLETE', \JVERSION), + Log::INFO, + 'Update' + ); return true; } @@ -420,7 +426,11 @@ public function processUpdatePackage($updateInformation) $this->progressBar->advance(); $file = $this->downloadFile($updateInformation['object']->downloadurl->_data); + if (!$file) { + return false; + } + Log::add(Text::sprintf('COM_JOOMLAUPDATE_UPDATE_LOG_FILE', $file), Log::INFO, 'Update'); $tmpPath = $this->getApplication()->get('tmp_path'); $updatePackage = $tmpPath . '/' . $file; @@ -436,6 +446,7 @@ public function processUpdatePackage($updateInformation) $this->progressBar->display(); $this->progressBar->advance(); + Log::add(Text::_('COM_JOOMLAUPDATE_UPDATE_LOG_INSTALL'), Log::INFO, 'Update'); $this->copyFileTo($package['extractdir'], JPATH_BASE); return ['file' => $updatePackage, 'extractdir' => $package['extractdir']];