mirror of
https://git.friendi.ca/friendica/friendica.git
synced 2025-06-08 11:54:32 +02:00
New post class in the rest of the classes
This commit is contained in:
parent
3ab4e20fe6
commit
2fa692bcce
15 changed files with 33 additions and 20 deletions
|
@ -5,6 +5,7 @@ namespace Friendica\Module\Update;
|
|||
use Friendica\Core\System;
|
||||
use Friendica\DI;
|
||||
use Friendica\Model\Item;
|
||||
use Friendica\Model\Post;
|
||||
use Friendica\Module\Conversation\Network as NetworkModule;
|
||||
|
||||
class Network extends NetworkModule
|
||||
|
@ -23,7 +24,7 @@ class Network extends NetworkModule
|
|||
|
||||
if (!DI::pConfig()->get($profile_uid, 'system', 'no_auto_update') || ($_GET['force'] == 1)) {
|
||||
if (!empty($_GET['item'])) {
|
||||
$item = Item::selectFirst(['parent'], ['id' => $_GET['item']]);
|
||||
$item = Post::selectFirst(['parent'], ['id' => $_GET['item']]);
|
||||
$parent = $item['parent'] ?? 0;
|
||||
} else {
|
||||
$parent = 0;
|
||||
|
|
|
@ -22,12 +22,12 @@
|
|||
namespace Friendica\Module\Update;
|
||||
|
||||
use Friendica\BaseModule;
|
||||
use Friendica\Content\Pager;
|
||||
use Friendica\Core\Session;
|
||||
use Friendica\Core\System;
|
||||
use Friendica\Database\DBA;
|
||||
use Friendica\DI;
|
||||
use Friendica\Model\Item;
|
||||
use Friendica\Model\Post;
|
||||
use Friendica\Model\Profile as ProfileModel;
|
||||
use Friendica\Network\HTTPException\ForbiddenException;
|
||||
use Friendica\Util\DateTimeFormat;
|
||||
|
@ -111,7 +111,7 @@ class Profile extends BaseModule
|
|||
}
|
||||
|
||||
if ($is_owner) {
|
||||
$unseen = Item::exists(['wall' => true, 'unseen' => true, 'uid' => local_user()]);
|
||||
$unseen = Post::exists(['wall' => true, 'unseen' => true, 'uid' => local_user()]);
|
||||
if ($unseen) {
|
||||
Item::update(['unseen' => false], ['wall' => true, 'unseen' => true, 'uid' => local_user()]);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue