Skip to content

Commit

Permalink
Fix execute() access in some controllers
Browse files Browse the repository at this point in the history
  • Loading branch information
felix-schindler committed Apr 30, 2022
1 parent 1af2ec8 commit 064c953
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Backend/Controllers/APIController.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ class APIController extends Controller
protected array $paths = ['/api/sample'];
protected array $methods = ['POST'];

public function execute(): void {
protected function execute(): void {
(new APIView())->render();
}
}
2 changes: 1 addition & 1 deletion Backend/Controllers/NotCalledController.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class NotCalledController extends Controller
{
protected array $paths = ['/:type/:id'];

public function execute(): void {
protected function execute(): void {
$layout = new LayoutView();
$layout->addChild(new HeadingView("Doesn't get called when only using links from the LayoutView"));
$layout->addChild(new TextView("Go and work on the Router!"));
Expand Down
2 changes: 1 addition & 1 deletion Backend/Controllers/SecondHome.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ class SecondHome extends Controller
{
protected array $paths = ['/article/:id'];

public function execute(): void {
protected function execute(): void {
$layout = new LayoutView();
$layout->addChild(new TextView("Welcome to another route"));
if (($id = $this->param("id")) !== null) {
Expand Down

0 comments on commit 064c953

Please sign in to comment.