Skip to content

Commit

Permalink
[HOTFIX] Broken DB upgrade for latest release
Browse files Browse the repository at this point in the history
  • Loading branch information
MPOS123 committed Apr 29, 2015
1 parent dfa34bc commit 38e9654
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions upgrade/definitions/1.0.0_to_1.0.1.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@ function run_101() {
$db_version_now = $setting->getValue('DB_VERSION'); // Our actual version installed

// Upgrade specific variables
$aSql[] = "ALTER TABLE `" . $coin_address->getTableName() . "` ADD ap_threshold float DEFAULT '0'";
$aSql[] = "ALTER TABLE " . $coin_address->getTableName() . " ADD ap_threshold float DEFAULT '0'";
$aSql[] = "UPDATE " . $coin_address->getTableName() . " AS ca LEFT JOIN " . $user->getTableName() . " AS a ON a.id = ca.account_id SET ca.ap_threshold = a.ap_threshold";
$aSql[] = "ALTER TABLE `" . $user->getTableName() . "` DROP `ap_threshold`";
$aSql[] = "ALTER TABLE " . $user->getTableName() . " DROP `ap_threshold`";
$aSql[] = "UPDATE " . $setting->getTableName() . " SET value = '1.0.1' WHERE name = 'DB_VERSION'";

if ($db_version_now == $db_version_old && version_compare($db_version_now, DB_VERSION, '<')) {
Expand Down

0 comments on commit 38e9654

Please sign in to comment.