repo = $repo; } function renderIndex(): void { if($_SERVER["REQUEST_METHOD"] === "POST") { $this->template->results = $repo->find([ "query" => $this->postParam("query"), ]); } } }