Skip to content

Commit 0071423

Browse files
committed
[FIX] Installer.
1 parent ebcc49a commit 0071423

1 file changed

Lines changed: 9 additions & 10 deletions

File tree

install/cli-install.php

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -385,23 +385,22 @@ public function checkIssetTablePrefix()
385385

386386
public function composerUpdate()
387387
{
388+
$disabled = array_map('trim', explode(',', ini_get('disable_functions') ?: ''));
388389
$composerBin = EVO_CORE_PATH . 'vendor/bin/composer';
389390
$workingDir = EVO_CORE_PATH;
390-
$cmd = sprintf(
391-
'php %s update --no-interaction --prefer-dist --working-dir=%s',
392-
escapeshellarg($composerBin),
393-
escapeshellarg($workingDir)
394-
);
395391

396392
if (!is_file($composerBin)) {
397393
warning("⚠ Local Composer not found: {$composerBin} Please perform 'composer install' or 'composer update' manually.");
398394
return;
399395
}
400396

401-
success("✔ Usage local Composer");
402-
info(" Running: {$cmd}");
397+
success("✔ Running composer update");
403398

404-
$disabled = array_map('trim', explode(',', ini_get('disable_functions') ?: ''));
399+
$cmd = sprintf(
400+
'php %s update --no-interaction --prefer-dist --working-dir=%s',
401+
escapeshellarg($composerBin),
402+
escapeshellarg($workingDir)
403+
);
405404

406405
$exitCode = null;
407406
if (!in_array('passthru', $disabled, true)) {
@@ -414,7 +413,7 @@ public function composerUpdate()
414413
$exitCode = (is_string($output) && $output !== '') ? 0 : 1;
415414
echo $output;
416415
} else {
417-
warning(' The passthru/exec/shell_exec functions are disabled in php.ini.');
416+
info('- The passthru/exec/shell_exec functions are disabled in php.ini.');
418417
warning('⚠ Run "composer update" manually.');
419418
return;
420419
}
@@ -446,7 +445,7 @@ public function writeConfig()
446445
$confph['connection_charset'] = $this->database_charset;
447446
$confph['connection_collation'] = $this->database_collation;
448447
$confph['connection_method'] = 'SET CHARACTER SET';
449-
$confph['dbase'] = str_replace('`', '', $this->database);
448+
$confph['dbase'] = str_replace('', '', $this->database);
450449
$confph['table_prefix'] = $this->tablePrefix;
451450
$confph['lastInstallTime'] = time();
452451
$confph['database_engine'] = '';

0 commit comments

Comments
 (0)