]> git.mxchange.org Git - friendica.git/blobdiff - src/BaseObject.php
Merge pull request #6773 from nupplaphil/issue/6772-update_query_missmatch
[friendica.git] / src / BaseObject.php
index d006c249defde79fc07243794a13d61ade733a8e..4a6fa12d24b03ad18f4542114f1302d8a9e3573e 100644 (file)
@@ -6,6 +6,8 @@ namespace Friendica;
 
 require_once 'boot.php';
 
+use Friendica\Network\HTTPException\InternalServerErrorException;
+
 /**
  * Basic object
  *
@@ -21,11 +23,12 @@ class BaseObject
         * Same as get_app from boot.php
         *
         * @return App
+        * @throws \Exception
         */
        public static function getApp()
        {
                if (empty(self::$app)) {
-                       self::$app = new App(dirname(__DIR__));
+                       throw new InternalServerErrorException('App isn\'t initialized.');
                }
 
                return self::$app;