diff options
Diffstat (limited to 'Zotlabs')
-rw-r--r-- | Zotlabs/Update/_1224.php | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/Zotlabs/Update/_1224.php b/Zotlabs/Update/_1224.php index d687afce7..d160cea5d 100644 --- a/Zotlabs/Update/_1224.php +++ b/Zotlabs/Update/_1224.php @@ -5,21 +5,24 @@ namespace Zotlabs\Update; class _1224 { function run() { - q("START TRANSACTION"); - if(ACTIVE_DBTYPE == DBTYPE_MYSQL) { + q("START TRANSACTION"); + $r1 = q("ALTER TABLE hubloc ALTER hubloc_id_url SET DEFAULT ''"); $r2 = q("ALTER TABLE hubloc ALTER hubloc_site_id SET DEFAULT ''"); - } - if($r1 && $r2) { - q("COMMIT"); + if($r1 && $r2) { + q("COMMIT"); + return UPDATE_SUCCESS; + } + + q("ROLLBACK"); + return UPDATE_FAILED; + } + if(ACTIVE_DBTYPE == DBTYPE_POSTGRES) { return UPDATE_SUCCESS; } - q("ROLLBACK"); - return UPDATE_FAILED; - } } |