<?php

namespace Inbox\Controller;

use App\Controller\App;

class Controller extends App {

    protected function render(string $view, array $params = []): mixed {

        $contents = $this->app->render($view, $params);

        $view = 'inbox:layouts/layout.php';
        $view .= $this->layout ? " with ".$this->layout:"";

        return $this->app->render($view, compact('contents'));
    }

}
