Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2013-10-25 17:38:08 +0400
committerMorris Jobke <morris.jobke@gmail.com>2013-11-01 13:57:39 +0400
commit979cabe0d4bbe51578bd7d998a06cdadb5d14ccf (patch)
tree54fd490e2c08653bf14bbc7dbe9a1db50ca6ae28
parent0df79dd409b00d86f957057be56efddb6b07276b (diff)
When updating an appstore app, execute a database update
See #5202
-rw-r--r--lib/installer.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/installer.php b/lib/installer.php
index 467e486dd29..3299fb07390 100644
--- a/lib/installer.php
+++ b/lib/installer.php
@@ -196,7 +196,11 @@ class OC_Installer{
//install the database
if(is_file($basedir.'/appinfo/database.xml')) {
- OC_DB::createDbFromStructure($basedir.'/appinfo/database.xml');
+ if (OC_Appconfig::getValue($info['id'], 'installed_version') === null) {
+ OC_DB::createDbFromStructure($basedir.'/appinfo/database.xml');
+ } else {
+ OC_DB::updateDbFromStructure($basedir.'/appinfo/database.xml');
+ }
}
//run appinfo/install.php