Fix missing PostRepository argument

This was accidentially removed in 9157efe426
This commit is contained in:
Alexander Skvortsov 2021-03-01 00:30:04 -05:00
parent 9157efe426
commit fa8a2e37e3

View File

@ -12,6 +12,7 @@ namespace Flarum\Api\Controller;
use Flarum\Api\Serializer\PostSerializer;
use Flarum\Http\UrlGenerator;
use Flarum\Post\Filter\PostFilterer;
use Flarum\Post\PostRepository;
use Flarum\Search\SearchCriteria;
use Illuminate\Support\Arr;
use Psr\Http\Message\ServerRequestInterface;
@ -46,6 +47,11 @@ class ListPostsController extends AbstractListController
*/
protected $filterer;
/**
* @var PostRepository
*/
protected $posts;
/**
* @var UrlGenerator
*/
@ -53,11 +59,13 @@ class ListPostsController extends AbstractListController
/**
* @param PostFilterer $filterer
* @param PostRepository $posts
* @param UrlGenerator $url
*/
public function __construct(PostFilterer $filterer, UrlGenerator $url)
public function __construct(PostFilterer $filterer, PostRepository $posts, UrlGenerator $url)
{
$this->filterer = $filterer;
$this->posts = $posts;
$this->url = $url;
}