title: passed to App\Models\Model::__construct() must be an instance
body: <p>i was trying to make master Model this error come:</p>
  
  <p>Fatal error: Uncaught TypeError: Argument 1 passed to App\Models\Model::__construct() must be an instance of App\Models\Database, instance of App\Database given, called in C:\xampp\htdocs\Work\AppDarbNajah\App\Controllers\ArticlesController.php on line 14 and defined in C:\xampp\htdocs\Work\AppDarbNajah\App\Models\Model.php:9 Stack trace: #0 C:\xampp\htdocs\Work\AppDarbNajah\App\Controllers\ArticlesController.php(14): App\Models\Model->__construct(Object(App\Database)) #1 C:\xampp\htdocs\Work\AppDarbNajah\Public\index.php(22): App\Controllers\ArticlesController->loadArticles() #2 {main} thrown in C:\xampp\htdocs\Work\AppDarbNajah\App\Models\Model.php on line 9</p>
  
  <p>My code is
  1- Model </p>
  
  <pre><code>&lt;?php
  namespace App\Models;
  
  
  class Model{
    protected $db;
    protected $table;
  
    public function __construct(Database $db){
       $this-&gt;db = $db;
    }
    public function query($statement, $attributes= null){
       return $this-&gt;db-&gt;query($statement);
    }
  }   
  </code></pre>
  
  <p>2- ArticlesController</p>
  
  <pre><code>&lt;?php
  namespace App\Controllers;
  
  
  use App\Models\ArticlesModel;
  
  class ArticlesController{
       public function loadArticles() {
  
       $app = new \App();
       $art_table = new ArticlesModel($app-&gt;getDb());
       return $art_table-&gt;load();
  
  
    }
  }
  </code></pre>