public function __invoke(ServerRequestInterface $request, ResponseInterface $response) { $comment = $this->repository->getMostRecent(); $this->view->render($response, 'post.phtml', ['comment' => new CommentViewModel($comment)]); }
public function __invoke(ServerRequestInterface $request, ResponseInterface $response) { $comment = $this->repository->getMostRecent(); $this->view->render($response, 'post.phtml', ['comment' => new CommentViewModel($comment)]); }