Index: branches/unlabeled/unlabeled-1.6.2/core/install.php =================================================================== diff -u -r7470 -r7471 --- branches/unlabeled/unlabeled-1.6.2/core/install.php (.../install.php) (revision 7470) +++ branches/unlabeled/unlabeled-1.6.2/core/install.php (.../install.php) (revision 7471) @@ -148,6 +148,7 @@ */ function SelectPreset() { + $preset = $this->GetVar('preset'); if (file_exists($this->INIFile) && $this->systemConfig) { // only at installation first step $status = $this->CheckDatabase(false); @@ -156,12 +157,8 @@ $this->currentStep = ''; } } - else { - $preset = $this->GetVar('preset'); - - if ($preset === false) { - $preset = 'fresh_install'; // default preset - } + if ($preset === false) { + $preset = 'fresh_install'; // default preset } $this->stepsPreset = $preset; @@ -365,6 +362,9 @@ $updater->OneStepRun(); break; + case 'finish': + $this->Conn->Query('INSERT INTO '.TABLE_PREFIX.'ConfigurationValues (VariableName, VariableValue) VALUE (\'InstallFinished\', 1)'); + break; } if ($this->errorMessage) { @@ -460,7 +460,8 @@ */ function AlreadyInstalled() { - return $this->TableExists('ConfigurationAdmin'); //,Category,Permissions'); + $table_prefix = $this->systemConfig['Database']['TablePrefix']; + return $this->TableExists('ConfigurationValues') && $this->Conn->GetOne('SELECT VariableValue FROM '.$table_prefix.'ConfigurationValues WHERE VariableName = \'InstallFinished\''); } function CheckDatabase($check_installed = true)