aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2013-10-25 15:38:08 +0200
committerBart Visscher <bartv@thisnet.nl>2013-10-25 15:38:08 +0200
commit310c8400df99ab073a1dbd03b78f57bab3de8e98 (patch)
treec01cf41f8b39a799c02324f7c74f5f8a3ab48839 /lib
parenta555e00e2cb2862211fa87e7b3351bab7d94c8bf (diff)
downloadnextcloud-server-310c8400df99ab073a1dbd03b78f57bab3de8e98.tar.gz
nextcloud-server-310c8400df99ab073a1dbd03b78f57bab3de8e98.zip
When updating an appstore app, execute a database update
See #5202
Diffstat (limited to 'lib')
-rw-r--r--lib/private/installer.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/private/installer.php b/lib/private/installer.php
index e082c7eeee9..363cd43628d 100644
--- a/lib/private/installer.php
+++ b/lib/private/installer.php
@@ -181,7 +181,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