I've been getting these two error messages. my code is
public function __construct() {
        $db->connect();
    }
    function connect() {
        return  new mysqli('localhost', DB_USER, DB_PASS,DB_NAME);
    }
Does anyone know what my issue is. i am still very new to PHP so sorry if this is a stupid question.
my DB_USER ,DB_PASS, DB_NAME are saved in my config file
 
    