Commit 743ed0730be12e29657303284ee69a29454ab3d8

Authored by Jarrett Jordaan
1 parent 01bf0e17

Configuration updated.

Committed by: Jarrett Jordaan

Reviewed by: Megan Watson
setup/wizard/steps/configuration.php
@@ -247,10 +247,12 @@ class configuration extends Step @@ -247,10 +247,12 @@ class configuration extends Step
247 public function doRun($edit = false) 247 public function doRun($edit = false)
248 { 248 {
249 $server = $this->getServerInfo(); 249 $server = $this->getServerInfo();
250 - if(!$edit) $this->temp_variables['server'] = $server; 250 + if(!$edit || $this->util->isMigration())
  251 + $this->temp_variables['server'] = $server;
251 252
252 $paths = $this->getPathInfo($server['file_system_root']['value']); 253 $paths = $this->getPathInfo($server['file_system_root']['value']);
253 - if(!$edit) $this->temp_variables['paths'] = $paths; 254 + if(!$edit || $this->util->isMigration())
  255 + $this->temp_variables['paths'] = $paths;
254 256
255 // Rewrite file system root 257 // Rewrite file system root
256 if(!$this->fpath) { 258 if(!$this->fpath) {
@@ -432,13 +434,15 @@ class configuration extends Step @@ -432,13 +434,15 @@ class configuration extends Step
432 { 434 {
433 if(isset($this->temp_variables['paths'])) { 435 if(isset($this->temp_variables['paths'])) {
434 if ($this->util->isMigration()) { // Check if its an upgrade 436 if ($this->util->isMigration()) { // Check if its an upgrade
435 - $this->readInstallation(); // Read values from config.ini of other installation 437 + $this->readConfigPath(); // Read contents of config-path file as only var Documents are used of old stack
  438 + $this->readInstallation(); // Read values from config.ini of other installation and overwrite config-path's
436 $dirs = $this->getFromConfigPath(); // Store contents 439 $dirs = $this->getFromConfigPath(); // Store contents
437 } else { 440 } else {
438 $dirs = $this->temp_variables['paths']; // Pull from temp 441 $dirs = $this->temp_variables['paths']; // Pull from temp
439 } 442 }
440 } else { 443 } else {
441 if ($this->util->isMigration()) { // Check if its an upgrade 444 if ($this->util->isMigration()) { // Check if its an upgrade
  445 + $this->readConfigPath(); // Read contents of config-path file as only var Documents are used of old stack
442 $this->readInstallation(); // Read values from config.ini of other installation 446 $this->readInstallation(); // Read values from config.ini of other installation
443 } else { 447 } else {
444 $this->readConfigPath(); // Read contents of config-path file 448 $this->readConfigPath(); // Read contents of config-path file
@@ -455,13 +459,13 @@ class configuration extends Step @@ -455,13 +459,13 @@ class configuration extends Step
455 } 459 }
456 if(WINDOWS_OS) 460 if(WINDOWS_OS)
457 $path = preg_replace('/\//', '\\',$path); 461 $path = preg_replace('/\//', '\\',$path);
458 - $dirs[$key]['path'] = $path;  
459 - $path = $class = strtolower(substr($path,0,1)).substr($path,1); // Damn you windows  
460 - if(isset($dir['file'])) {  
461 - $class = $this->util->checkPermission($path, false, true);  
462 - } else {  
463 - $class = $this->util->checkPermission($path, $dir['create']);  
464 - } 462 + $dirs[$key]['path'] = $path;
  463 + $path = $class = strtolower(substr($path,0,1)).substr($path,1); // Damn you windows
  464 + if(isset($dir['file'])) {
  465 + $class = $this->util->checkPermission($path, false, true);
  466 + } else {
  467 + $class = $this->util->checkPermission($path, $dir['create']);
  468 + }
465 if(isset($class['msg'])) { 469 if(isset($class['msg'])) {
466 if($class['class'] != 'tick') { 470 if($class['class'] != 'tick') {
467 $this->temp_variables['paths_perms'] = $class['class']; 471 $this->temp_variables['paths_perms'] = $class['class'];