From 8eefd42a7dc537ebf28e2a3827e01c42b266dcd1 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Thu, 21 Jul 2011 00:52:48 +0200 Subject: [PATCH] only remove old sqlite database if it exists --- lib/setup.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/setup.php b/lib/setup.php index 1a33209ec57..63ba4daab54 100644 --- a/lib/setup.php +++ b/lib/setup.php @@ -131,7 +131,9 @@ class OC_SETUP { } else { //delete the old sqlite database first, might cause infinte loops otherwise - unlink("$datadir/owncloud.db"); + if(file_exists("$datadir/owncloud.db")){ + unlink("$datadir/owncloud.db"); + } //in case of sqlite, we can always fill the database OC_DB::createDbFromStructure('db_structure.xml'); } -- 2.39.5