Update installer the right way
This commit is contained in:
parent
bed05b0592
commit
027ff8f029
@ -1,4 +1,4 @@
|
||||
<?php
|
||||
|
||||
// Define the current build
|
||||
define('MODS_FOR_HESK_BUILD', 38);
|
||||
define('MODS_FOR_HESK_BUILD', 40);
|
@ -84,6 +84,8 @@ if ($version == 2) {
|
||||
execute304Scripts();
|
||||
} elseif ($version == 39) {
|
||||
execute305Scripts();
|
||||
} elseif ($version == 40) {
|
||||
execute306Scripts();
|
||||
} else {
|
||||
$response = 'The version "' . $version . '" was not recognized. Check the value submitted and try again.';
|
||||
print $response;
|
||||
|
@ -48,6 +48,7 @@ $buildToVersionMap = array(
|
||||
37 => '3.0.3',
|
||||
38 => '3.0.4',
|
||||
39 => '3.0.5',
|
||||
40 => '3.0.6',
|
||||
);
|
||||
|
||||
function echoInitialVersionRows($version, $build_to_version_map)
|
||||
|
@ -113,6 +113,9 @@ function processUpdates(startingVersion) {
|
||||
} else if (startingVersion < 39) {
|
||||
startVersionUpgrade('305');
|
||||
executeUpdate(39, '305', '3.0.5');
|
||||
} else if (startingVersion < 40) {
|
||||
startVersionUpgrade('306');
|
||||
executeUpdate(40, '306', '3.0.6');
|
||||
} else {
|
||||
installationFinished();
|
||||
}
|
||||
|
@ -974,6 +974,12 @@ function execute305Scripts() {
|
||||
updateVersion('3.0.5');
|
||||
}
|
||||
|
||||
function execute306Scripts() {
|
||||
global $hesk_settings;
|
||||
hesk_dbConnect();
|
||||
|
||||
updateVersion('3.0.6');
|
||||
}
|
||||
function execute310Scripts() {
|
||||
global $hesk_settings;
|
||||
hesk_dbConnect();
|
||||
|
Loading…
x
Reference in New Issue
Block a user