aboutsummaryrefslogtreecommitdiffstats
path: root/install/update.php
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2016-05-31 11:01:24 +0200
committerMario Vavti <mario@mariovavti.com>2016-05-31 11:01:24 +0200
commit380f65d309a6ab01d8e804f704962d5baef9820a (patch)
tree896fd1d53ccb3863380653d1b065c7fc4ef7a641 /install/update.php
parent90f29590765f79fe4bd1e3d59e47ce932ec04d0d (diff)
parent670e83b30050201e3ac069c9dfa86a92aff2431d (diff)
downloadvolse-hubzilla-380f65d309a6ab01d8e804f704962d5baef9820a.tar.gz
volse-hubzilla-380f65d309a6ab01d8e804f704962d5baef9820a.tar.bz2
volse-hubzilla-380f65d309a6ab01d8e804f704962d5baef9820a.zip
Merge branch 'dev' into sabre32
Diffstat (limited to 'install/update.php')
-rw-r--r--install/update.php20
1 files changed, 19 insertions, 1 deletions
diff --git a/install/update.php b/install/update.php
index 983db1bb9..686c199b5 100644
--- a/install/update.php
+++ b/install/update.php
@@ -1,6 +1,6 @@
<?php
-define( 'UPDATE_VERSION' , 1169 );
+define( 'UPDATE_VERSION' , 1170 );
/**
*
@@ -2114,3 +2114,21 @@ function update_r1168() {
return UPDATE_FAILED;
}
+function update_r1169() {
+
+ if(ACTIVE_DBTYPE == DBTYPE_POSTGRES) {
+ $r1 = q("ALTER TABLE `addon` CHANGE `timestamp` `tstamp` numeric( 20 ) UNSIGNED NOT NULL DEFAULT '0' ");
+ $r2 = q("ALTER TABLE `addon` CHANGE `name` `aname` text NOT NULL DEFAULT '' ");
+ $r3 = q("ALTER TABLE `hook` CHANGE `function` `fn` text NOT NULL DEFAULT '' ");
+
+ }
+ else {
+ $r1 = q("ALTER TABLE `addon` CHANGE `timestamp` `tstamp` BIGINT( 20 ) UNSIGNED NOT NULL DEFAULT '0' ");
+ $r2 = q("ALTER TABLE `addon` CHANGE `name` `aname` CHAR(255) NOT NULL DEFAULT '' ");
+ $r3 = q("ALTER TABLE `hook` CHANGE `function` `fn` CHAR(255) NOT NULL DEFAULT '' ");
+ }
+
+ if($r1 && $r2 && $r3)
+ return UPDATE_SUCCESS;
+ return UPDATE_FAILED;
+} \ No newline at end of file