public function __construct(AbstractController $controller = null) { $this->config = Config::parseConfig(DEFAULT_CONFIG_PATH, CONFIG_PATH); $this->language = new Language(); if (!empty($controller)) { $this->view = $controller->getView(); } else { $this->setView(); } }