mirror of
https://github.com/openvk/openvk
synced 2025-04-23 00:23:01 +03:00
PHP 8 FIX WATAFAK
This commit is contained in:
parent
12775d0a09
commit
029ce27e41
3 changed files with 3 additions and 3 deletions
|
@ -132,7 +132,7 @@ class Wall implements Handler
|
|||
];
|
||||
|
||||
foreach($videos as $video) {
|
||||
$res = json_decode(json_encode($video->toVkApiStruct()), true);
|
||||
$res = json_decode(json_encode($video->toVkApiStruct($this->user)), true);
|
||||
$res["video"]["author_name"] = $video->getOwner()->getCanonicalName();
|
||||
|
||||
$arr["items"][] = $res;
|
||||
|
|
|
@ -448,11 +448,11 @@ final class GroupPresenter extends OpenVKPresenter
|
|||
}
|
||||
|
||||
if(!$club->canBeModifiedBy($this->user->identity)) {
|
||||
$this->template->posts = (new Posts)->getSuggestedPostsByUser($club->getId(), $this->user->id, (int) ($this->queryParam("p") ?? 1));
|
||||
$this->template->posts = iterator_to_array((new Posts)->getSuggestedPostsByUser($club->getId(), $this->user->id, (int) ($this->queryParam("p") ?? 1)));
|
||||
$this->template->count = (new Posts)->getSuggestedPostsCountByUser($club->getId(), $this->user->id);
|
||||
$this->template->type = "my";
|
||||
} else {
|
||||
$this->template->posts = (new Posts)->getSuggestedPosts($club->getId(), (int) ($this->queryParam("p") ?? 1));
|
||||
$this->template->posts = iterator_to_array((new Posts)->getSuggestedPosts($club->getId(), (int) ($this->queryParam("p") ?? 1)));
|
||||
$this->template->count = (new Posts)->getSuggestedPostsCount($club->getId());
|
||||
$this->template->type = "everyone";
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue