Database version increased, code simplified

This commit is contained in:
Michael 2022-02-15 15:44:44 +00:00
parent 29d83c0ffb
commit d019ef57d2
3 changed files with 6 additions and 11 deletions

View File

@ -1,6 +1,6 @@
-- ------------------------------------------ -- ------------------------------------------
-- Friendica 2022.05-dev (Siberian Iris) -- Friendica 2022.05-dev (Siberian Iris)
-- DB_UPDATE_VERSION 1451 -- DB_UPDATE_VERSION 1452
-- ------------------------------------------ -- ------------------------------------------

View File

@ -2516,11 +2516,6 @@ class Item
return true; return true;
} }
$allow_cid = $allow_cid ?? $item['allow_cid'];
$allow_gid = $allow_gid ?? $item['allow_gid'];
$deny_cid = $deny_cid ?? $item['deny_cid'];
$deny_gid = $deny_gid ?? $item['deny_gid'];
$objtype = $item['resource-id'] ? Activity\ObjectType::IMAGE : Activity\ObjectType::NOTE; $objtype = $item['resource-id'] ? Activity\ObjectType::IMAGE : Activity\ObjectType::NOTE;
$new_item = [ $new_item = [
@ -2541,10 +2536,10 @@ class Item
'body' => $activity, 'body' => $activity,
'verb' => $activity, 'verb' => $activity,
'object-type' => $objtype, 'object-type' => $objtype,
'allow_cid' => $allow_cid, 'allow_cid' => $allow_cid ?? $item['allow_cid'],
'allow_gid' => $allow_gid, 'allow_gid' => $allow_gid ?? $item['allow_gid'],
'deny_cid' => $deny_cid, 'deny_cid' => $deny_cid ?? $item['deny_cid'],
'deny_gid' => $deny_gid, 'deny_gid' => $deny_gid ?? $item['deny_gid'],
'visible' => 1, 'visible' => 1,
'unseen' => 1, 'unseen' => 1,
]; ];

View File

@ -55,7 +55,7 @@
use Friendica\Database\DBA; use Friendica\Database\DBA;
if (!defined('DB_UPDATE_VERSION')) { if (!defined('DB_UPDATE_VERSION')) {
define('DB_UPDATE_VERSION', 1451); define('DB_UPDATE_VERSION', 1452);
} }
return [ return [