Merge pull request #17954 from nextcloud/backport/17942/stable15
[stable15] pass through ServerNotAvailableException on app init
This commit is contained in:
commit
ae00845ffc
|
@ -55,6 +55,7 @@ use OC\App\Platform;
|
||||||
use OC\DB\MigrationService;
|
use OC\DB\MigrationService;
|
||||||
use OC\Installer;
|
use OC\Installer;
|
||||||
use OC\Repair;
|
use OC\Repair;
|
||||||
|
use OC\ServerNotAvailableException;
|
||||||
use OCP\App\ManagerEvent;
|
use OCP\App\ManagerEvent;
|
||||||
use OCP\ILogger;
|
use OCP\ILogger;
|
||||||
|
|
||||||
|
@ -153,6 +154,9 @@ class OC_App {
|
||||||
try {
|
try {
|
||||||
self::requireAppFile($app);
|
self::requireAppFile($app);
|
||||||
} catch (Throwable $ex) {
|
} catch (Throwable $ex) {
|
||||||
|
if($ex instanceof ServerNotAvailableException) {
|
||||||
|
throw $ex;
|
||||||
|
}
|
||||||
\OC::$server->getLogger()->logException($ex);
|
\OC::$server->getLogger()->logException($ex);
|
||||||
if (!\OC::$server->getAppManager()->isShipped($app)) {
|
if (!\OC::$server->getAppManager()->isShipped($app)) {
|
||||||
// Only disable apps which are not shipped
|
// Only disable apps which are not shipped
|
||||||
|
|
Loading…
Reference in New Issue