X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=src%2FBaseObject.php;h=d006c249defde79fc07243794a13d61ade733a8e;hb=b0d8a2fcd087c2a7c34460ced3c7334eccaa1c0a;hp=01957164c10bd664fbd536b2f6c0680b5af8e9c9;hpb=f43aaf5227af34b870bae3715f2cb1de293aa272;p=friendica.git diff --git a/src/BaseObject.php b/src/BaseObject.php index 01957164c1..d006c249de 100644 --- a/src/BaseObject.php +++ b/src/BaseObject.php @@ -20,27 +20,25 @@ class BaseObject * * Same as get_app from boot.php * - * @return object + * @return App */ public static function getApp() { - if (self::$app) { - return self::$app; + if (empty(self::$app)) { + self::$app = new App(dirname(__DIR__)); } - self::$app = get_app(); - return self::$app; } /** * Set the app * - * @param object $app App + * @param App $app App * * @return void */ - public static function setApp($app) + public static function setApp(App $app) { self::$app = $app; }