mirror of
https://git.sekbaer.de/Friendica/friendica.git
synced 2025-06-16 20:05:14 +02:00
db installation sync
This commit is contained in:
parent
b346f4464c
commit
d79c3351ea
4 changed files with 22 additions and 3 deletions
18
update.php
18
update.php
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
|
||||
define( 'UPDATE_VERSION' , 1120 );
|
||||
define( 'UPDATE_VERSION' , 1121 );
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -1021,3 +1021,19 @@ q("ALTER TABLE `contact` ADD `closeness` TINYINT( 2 ) NOT NULL DEFAULT '99' AFTE
|
|||
q("update contact set closeness = 0 where self = 1");
|
||||
q("ALTER TABLE `item` ADD `spam` TINYINT( 1 ) NOT NULL DEFAULT '0' AFTER `visible` , ADD INDEX (`spam`) ");
|
||||
}
|
||||
|
||||
|
||||
function update_1120() {
|
||||
|
||||
// item table update from 1119 did not get into database.sql file.
|
||||
// might be missing on new installs. We'll check.
|
||||
|
||||
$r = q("describe item");
|
||||
if($r && count($r)) {
|
||||
foreach($r as $rr)
|
||||
if($rr['Field'] == 'spam')
|
||||
return;
|
||||
}
|
||||
q("ALTER TABLE `item` ADD `spam` TINYINT( 1 ) NOT NULL DEFAULT '0' AFTER `visible` , ADD INDEX (`spam`) ");
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue