]> git.mxchange.org Git - friendica.git/blobdiff - src/BaseObject.php
Filesystem storage: handle basepath with trailing slash
[friendica.git] / src / BaseObject.php
index 6b64daccf0d8dbbd3bc47d75cd7964db0fbc8e28..84ff193823113a1534e3e407ac2eb712f3fda5f0 100644 (file)
@@ -6,6 +6,8 @@ namespace Friendica;
 
 require_once 'boot.php';
 
+use Friendica\Util\LoggerFactory;
+
 /**
  * Basic object
  *
@@ -21,11 +23,13 @@ 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__));
+                       $logger = $logger = LoggerFactory::create('app');
+                       self::$app = new App(dirname(__DIR__), $logger);
                }
 
                return self::$app;
@@ -34,7 +38,7 @@ class BaseObject
        /**
         * Set the app
         *
-        * @param object $app App
+        * @param App $app App
         *
         * @return void
         */