]> git.mxchange.org Git - friendica.git/blobdiff - src/Core/Addon.php
Remove duplicate profile_uid key in App->profile array
[friendica.git] / src / Core / Addon.php
index 59e1ec7b96d2b2f9ad4819604848376c37abdc09..5f1865b554898608aff5616a3c0539660417587b 100644 (file)
@@ -45,7 +45,7 @@ class Addon
                                        list($tmp, $addon) = array_map('trim', explode('/', $file));
                                        $info = self::getInfo($addon);
 
-                                       if (Config::get('system', 'show_unsupported_addons')
+                                       if (DI::config()->get('system', 'show_unsupported_addons')
                                                || strtolower($info['status']) != 'unsupported'
                                                || self::isEnabled($addon)
                                        ) {
@@ -83,7 +83,7 @@ class Addon
 
 
        /**
-        * @brief Synchronize addons:
+        * Synchronize addons:
         *
         * system.addon contains a comma-separated list of names
         * of addons which are used on this system.
@@ -103,7 +103,7 @@ class Addon
                        $installed_addons = DBA::toArray($r);
                }
 
-               $addons = Config::get('system', 'addon');
+               $addons = DI::config()->get('system', 'addon');
                $addons_arr = [];
 
                if ($addons) {
@@ -130,7 +130,7 @@ class Addon
        }
 
        /**
-        * @brief uninstalls an addon.
+        * uninstalls an addon.
         *
         * @param string $addon name of the addon
         * @return void
@@ -157,7 +157,7 @@ class Addon
        }
 
        /**
-        * @brief installs an addon.
+        * installs an addon.
         *
         * @param string $addon name of the addon
         * @return bool
@@ -210,7 +210,7 @@ class Addon
         */
        public static function reload()
        {
-               $addons = Config::get('system', 'addon');
+               $addons = DI::config()->get('system', 'addon');
                if (strlen($addons)) {
                        $r = DBA::select('addon', [], ['installed' => 1]);
                        if (DBA::isResult($r)) {
@@ -249,7 +249,7 @@ class Addon
        }
 
        /**
-        * @brief Parse addon comment in search of addon infos.
+        * Parse addon comment in search of addon infos.
         *
         * like
         * \code
@@ -286,7 +286,7 @@ class Addon
 
                $stamp1 = microtime(true);
                $f = file_get_contents("addon/$addon/$addon.php");
-               $a->getProfiler()->saveTimestamp($stamp1, "file", System::callstack());
+               DI::profiler()->saveTimestamp($stamp1, "file", System::callstack());
 
                $r = preg_match("|/\*.*\*/|msU", $f, $m);
 
@@ -348,7 +348,7 @@ class Addon
         */
        public static function saveEnabledList()
        {
-               return Config::set('system', 'addon', implode(',', self::$addons));
+               return DI::config()->set('system', 'addon', implode(',', self::$addons));
        }
 
        /**