From b096fd9ed8811c92177864f76e91ae939d42ead4 Mon Sep 17 00:00:00 2001
From: Robin Appelman <icewind@owncloud.com>
Date: Sat, 19 May 2012 01:55:20 +0200
Subject: [PATCH] log upgrades

---
 lib/app.php  | 2 +-
 lib/base.php | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/app.php b/lib/app.php
index 554724d238..7cb18a7ab0 100644
--- a/lib/app.php
+++ b/lib/app.php
@@ -495,7 +495,6 @@ class OC_App{
 	 * check if any apps need updating and update those
 	 */
 	public static function updateApps(){
-		// The rest comes here
 		$versions = self::getAppVersions();
 		//ensure files app is installed for upgrades
 		if(!isset($versions['files'])){
@@ -505,6 +504,7 @@ class OC_App{
 			$currentVersion=OC_App::getAppVersion($app);
 			if ($currentVersion) {
 				if (version_compare($currentVersion, $installedVersion, '>')) {
+					OC_Log::write($app,'starting app upgrade from '.$installedVersion.' to '.$currentVersion,OC_Log::DEBUG);
 					OC_App::updateApp($app);
 					OC_Appconfig::setValue($app,'installed_version',OC_App::getAppVersion($app));
 				}
diff --git a/lib/base.php b/lib/base.php
index 52a497e076..fb2d978f44 100644
--- a/lib/base.php
+++ b/lib/base.php
@@ -223,6 +223,7 @@ class OC{
 			$installedVersion=OC_Config::getValue('version','0.0.0');
 			$currentVersion=implode('.',OC_Util::getVersion());
 			if (version_compare($currentVersion, $installedVersion, '>')) {
+				OC_Log::write('core','starting upgrade from '.$installedVersion.' to '.$currentVersion,OC_Log::DEBUG);
 				$result=OC_DB::updateDbFromStructure(OC::$SERVERROOT.'/db_structure.xml');
 				if(!$result){
 					echo 'Error while upgrading the database';
-- 
GitLab