X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FCore%2FUpdate.php;h=7b2624cb9c638ae67eda5cd7c73c0c1cc840d8ab;hb=1cab44827f384efce7c48644a2e9a75887bdba38;hp=13968833576bdc4910dc8210fa6541f86a002354;hpb=bd972151478f40f73585519110700222a1931d44;p=friendica.git diff --git a/src/Core/Update.php b/src/Core/Update.php index 1396883357..7b2624cb9c 100644 --- a/src/Core/Update.php +++ b/src/Core/Update.php @@ -4,6 +4,7 @@ namespace Friendica\Core; use Friendica\Database\DBA; use Friendica\Database\DBStructure; +use Friendica\Util\Strings; class Update { @@ -17,6 +18,10 @@ class Update */ public static function check($via_worker) { + if (!DBA::connected()) { + return; + } + $build = Config::get('system', 'build'); if (empty($build)) { @@ -117,6 +122,8 @@ class Update Lock::release('dbupdate'); } } + } elseif ($force) { + DBStructure::update($verbose, true); } return ''; @@ -209,7 +216,7 @@ class Update $lang = (($admin['language'])?$admin['language']:'en'); L10n::pushLang($lang); - $preamble = deindent(L10n::t(" + $preamble = Strings::deindent(L10n::t(" The friendica developers released update %s recently, but when I tried to install it, something went terribly wrong. This needs to be fixed soon and I can't do it alone. Please contact a @@ -244,7 +251,7 @@ class Update $lang = (($admin['language']) ? $admin['language'] : 'en'); L10n::pushLang($lang); - $preamble = deindent(L10n::t(" + $preamble = Strings::deindent(L10n::t(" The friendica database was successfully updated from %s to %s.", $from_build, $to_build));