From a5f0cc653963210228b1992568286f6e4330aff3 Mon Sep 17 00:00:00 2001 From: Daniel Kesselberg Date: Sun, 23 Sep 2018 15:52:28 +0200 Subject: --database-name or --database-table-prefix are ignored for sqlite The default implementation of initialize in AbstractDatabase writes database information to config.php. The method is overwritten in Sqlite but parent is never called. Database-Name and Database-Table-Prefix are never written to config.php. But from this point setup use values from config. Signed-off-by: Daniel Kesselberg --- lib/private/Setup/Sqlite.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'lib/private') diff --git a/lib/private/Setup/Sqlite.php b/lib/private/Setup/Sqlite.php index d95e70c8b0c..406c1e6fc9a 100644 --- a/lib/private/Setup/Sqlite.php +++ b/lib/private/Setup/Sqlite.php @@ -20,6 +20,7 @@ * along with this program. If not, see * */ + namespace OC\Setup; class Sqlite extends AbstractDatabase { @@ -29,14 +30,11 @@ class Sqlite extends AbstractDatabase { return array(); } - public function initialize($config) { - } - public function setupDatabase($username) { $datadir = $this->config->getValue('datadirectory', \OC::$SERVERROOT . '/data'); //delete the old sqlite database first, might cause infinte loops otherwise - if(file_exists("$datadir/owncloud.db")) { + if (file_exists("$datadir/owncloud.db")) { unlink("$datadir/owncloud.db"); } //in case of sqlite, we can always fill the database -- cgit v1.2.3