add optional config filename to the app constructor

This commit is contained in:
yggverse 2024-06-27 16:56:03 +03:00
parent 338cb5fa1f
commit cf246ee53d

View file

@ -15,10 +15,13 @@ class App
public \GtkHeaderBar $header; public \GtkHeaderBar $header;
public \GtkNotebook $tabs; public \GtkNotebook $tabs;
public function __construct() public function __construct(
{ ?string $config = null
) {
// Init config // Init config
$this->config = new \Yggverse\Yoda\Model\Config; $this->config = new \Yggverse\Yoda\Model\Config(
$config
);
// Init database // Init database
$this->database = new \Yggverse\Yoda\Model\Database( $this->database = new \Yggverse\Yoda\Model\Database(