From 9dee79ba0075b786427df7b46cdb9c4d568ec410 Mon Sep 17 00:00:00 2001 From: Taylor Otwell Date: Tue, 27 Mar 2012 10:25:42 -0500 Subject: [PATCH] Fixing SQLite connector. Signed-off-by: Taylor Otwell --- laravel/database/connectors/sqlite.php | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/laravel/database/connectors/sqlite.php b/laravel/database/connectors/sqlite.php index e7867532..1e2fc7e5 100644 --- a/laravel/database/connectors/sqlite.php +++ b/laravel/database/connectors/sqlite.php @@ -20,21 +20,7 @@ public function connect($config) return new PDO('sqlite::memory:', null, null, $options); } - // We'll allow the "database" configuration option to be a fully qualified - // path to the database so we'll check if that is the case first. If it - // isn't a fully qualified path we will use the storage directory. - if (file_exists($config['database'])) - { - $path = $config['database']; - } - - // The database option does not appear to be a fully qualified path so we - // will just assume it is a relative path from the storage directory - // which is typically used to store all SQLite databases. - else - { - $path = path('storage').'database'.DS.$config['database'].'.sqlite'; - } + $path = path('storage').'database'.DS.$config['database'].'.sqlite'; return new PDO('sqlite:'.$path, null, null, $options); }