aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Update/_1224.php
blob: d687afce780909f0408bfa71e0c769a4db51f19b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?php

namespace Zotlabs\Update;

class _1224 {

	function run() {
		q("START TRANSACTION");

		if(ACTIVE_DBTYPE == DBTYPE_MYSQL) {
			$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");
			return UPDATE_SUCCESS;
		}

		q("ROLLBACK");
		return UPDATE_FAILED;

	}

}