various minor bugfixes; composer requirements update

Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann
2022-08-10 00:17:11 +02:00
parent 31500522ce
commit 50e35e149c
45 changed files with 397 additions and 354 deletions

View File

@@ -28,6 +28,7 @@ namespace Froxlor\Cli;
use Exception;
use Froxlor\Froxlor;
use Froxlor\Settings;
use Froxlor\Database\Database;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
@@ -72,7 +73,7 @@ class CliCommand extends Command
include_once Froxlor::getInstallDir() . '/install/updatesql.php';
ob_end_flush();
$output->writeln('<info>Automatic update done - you should check your settings to be sure everything is fine</>');
return self::SUCCCESS;
return self::SUCCESS;
}
private function cleanUpdateOutput($buffer)

View File

@@ -25,6 +25,7 @@
namespace Froxlor\Cli;
use PDO;
use Froxlor\Froxlor;
use Froxlor\FileDir;
use Froxlor\Settings;
@@ -32,6 +33,7 @@ use Froxlor\FroxlorLogger;
use Froxlor\Database\Database;
use Froxlor\System\Cronjob;
use Froxlor\Cron\TaskId;
use Froxlor\Cron\CronConfig;
use Froxlor\Cron\System\Extrausers;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Input\InputOption;
@@ -142,7 +144,7 @@ final class MasterCron extends CliCommand
// we have to check the system's last guid with every cron run
// in case the admin installed new software which added a new user
//so users in the database don't conflict with system users
$this->cronlog->logAction(FroxlorLogger::CRON_ACTION, LOG_NOTICE, 'Checking system\'s last guid');
$this->cronLog->logAction(FroxlorLogger::CRON_ACTION, LOG_NOTICE, 'Checking system\'s last guid');
Cronjob::checkLastGuid();
// check for cron.d-generation task and create it if necessary
@@ -160,7 +162,7 @@ final class MasterCron extends CliCommand
{
if ($jobcount > 0) {
if (Settings::Get('system.nssextrausers') == 1) {
Extrausers::generateFiles(self::$cronlog);
Extrausers::generateFiles($this->cronLog);
return;
}

View File

@@ -143,7 +143,7 @@ final class UpdateCommand extends CliCommand
$auex = AutoUpdate::extractZip($audl);
if ($auex == 0) {
$output->writeln("<info>Froxlor files updated successfully.</>");
$result = self::SUCCCESS;
$result = self::SUCCESS;
$question = new ConfirmationQuestion('Update database? [no] ', false, '/^(y|j)/i');
if ($yestoall || $helper->ask($input, $output, $question)) {
$result = $this->updateDatabase();
@@ -193,7 +193,7 @@ final class UpdateCommand extends CliCommand
]);
include_once Froxlor::getInstallDir() . '/install/updatesql.php';
ob_end_flush();
return self::SUCCCESS;
return self::SUCCESS;
}
private function cleanUpdateOutput($buffer)