Skip to content

Commit b04c67c

Browse files
author
Raeen
committed
update
1 parent 0e90453 commit b04c67c

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

core/Application.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ class Application
1313
public File $file;
1414
public DB $db;
1515
public static Application $app;
16-
public function __construct($rootPath)
16+
public function __construct()
1717
{
1818
$dotenv = Dotenv::createImmutable(dirname(__DIR__));
1919
$dotenv->load();
20-
self::$ROOT_DIR = dirname($rootPath);
20+
self::$ROOT_DIR = dirname(__DIR__);
2121
self::$app = $this;
2222
$this->request = new Request();
2323
$this->response = new Response();

public/index.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
use app\core\Application;
44

55
require_once __DIR__ . "/../vendor/autoload.php";
6-
$app = new Application(__DIR__);
6+
$app = new Application();
77
$router = $app->router;
88
//Routes
99
$router->post('/api', 'Api');

0 commit comments

Comments
 (0)