diff options
author | Haakon Meland Eriksen <haakon.eriksen@far.no> | 2015-09-11 06:42:11 +0200 |
---|---|---|
committer | Haakon Meland Eriksen <haakon.eriksen@far.no> | 2015-09-11 06:42:11 +0200 |
commit | edb1473f13a87ccfdfe2555ac9ab798fbc073805 (patch) | |
tree | 18a15afbca3cdbbf262e0737d01e23e7b4905cf1 /install/update.php | |
parent | 2f73d24ab134391c3b3a69d5cbfede42e028b5ed (diff) | |
parent | f2171173fe2c9a0596672da293eb756a514ff789 (diff) | |
download | volse-hubzilla-edb1473f13a87ccfdfe2555ac9ab798fbc073805.tar.gz volse-hubzilla-edb1473f13a87ccfdfe2555ac9ab798fbc073805.tar.bz2 volse-hubzilla-edb1473f13a87ccfdfe2555ac9ab798fbc073805.zip |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'install/update.php')
-rw-r--r-- | install/update.php | 28 |
1 files changed, 17 insertions, 11 deletions
diff --git a/install/update.php b/install/update.php index 8e531b595..339d0cb25 100644 --- a/install/update.php +++ b/install/update.php @@ -1,6 +1,6 @@ <?php -define( 'UPDATE_VERSION' , 1151 ); +define( 'UPDATE_VERSION' , 1152 ); /** * @@ -1733,16 +1733,6 @@ function update_r1148() { $r1 = q("alter table likes add i_mid char(255) not null default '' "); $r2 = q("create index i_mid on likes ( i_mid ) "); - $r3 = q("select likes.*, item.mid from from likes left join item on likes.iid = item.id"); - if($r3) { - foreach($r3 as $rr) { - q("update likes set i_mid = '%s' where id = $d", - dbesc($rr['mid']), - intval($rr['id']) - ); - } - } - if($r1 && $r2) return UPDATE_SUCCESS; return UPDATE_FAILED; @@ -1798,3 +1788,19 @@ function update_r1150() { } +function update_r1151() { + + $r3 = q("select likes.*, item.mid from likes left join item on likes.iid = item.id"); + if($r3) { + foreach($r3 as $rr) { + q("update likes set i_mid = '%s' where id = $d", + dbesc($rr['mid']), + intval($rr['id']) + ); + } + } + + + return UPDATE_SUCCESS; + +} |