1
1
Fork 0

Most functions now moved from include/items.php

This commit is contained in:
Michael 2018-01-28 11:18:08 +00:00
commit 7b27dda784
22 changed files with 1488 additions and 1523 deletions

View file

@ -4731,7 +4731,7 @@ function post_photo_item($hash, $allow_cid, $deny_cid, $allow_gid, $deny_gid, $f
. '[/url]';
// do the magic for storing the item in the database and trigger the federation to other contacts
item_store($arr);
Item::insert($arr);
}
/**

View file

@ -11,6 +11,7 @@ use Friendica\Core\L10n;
use Friendica\Core\PConfig;
use Friendica\Core\System;
use Friendica\Database\DBM;
use Friendica\Model\Item;
use Friendica\Model\Profile;
use Friendica\Util\Map;
@ -399,7 +400,7 @@ function event_store($arr) {
$item_arr['object'] .= '<content>' . xmlify(format_event_bbcode($event)) . '</content>';
$item_arr['object'] .= '</object>' . "\n";
$item_id = item_store($item_arr);
$item_id = Item::insert($item_arr);
if ($item_id) {
q("UPDATE `item` SET `event-id` = %d WHERE `uid` = %d AND `id` = %d",
intval($event['id']),

File diff suppressed because it is too large Load diff

View file

@ -9,6 +9,7 @@ use Friendica\Core\System;
use Friendica\Core\Worker;
use Friendica\Database\DBM;
use Friendica\Model\Contact;
use Friendica\Model\Item;
use Friendica\Protocol\Diaspora;
/**
@ -244,7 +245,7 @@ EOT;
'unseen' => 1,
];
$new_item_id = item_store($new_item);
$new_item_id = Item::insert($new_item);
// @todo: Explain this block
if (! $item['visible']) {