public function hasDatabase()
    {
        try {
            $hasDatabase = is_null($this->hasDatabase)
                ? $this['db.connection']->getSchemaBuilder()->hasTable('settings')
                : $this->hasDatabase;
        }
        catch (Exception $ex) {
            $hasDatabase = FALSE;
        }

        return $this->hasDatabase = $hasDatabase;
    }