config; $database = new Database($config['database']); $session = new Session; $user = new User($session, $database); new AccessControl($user); $app = new App( $config, $database, $session, $user ); // We will use $app instead unset( $config, $database, $session, $user ); return $app;