]> git.mxchange.org Git - friendica.git/blobdiff - view/theme/frio/php/scheme.php
Merge pull request #6589 from rabuzarus/20190204_-_show_forum_account_in_vcard
[friendica.git] / view / theme / frio / php / scheme.php
index 538839b2c256f8623b3b66a80c7acaa0816082aa..2f091804394b3eade1d485a00dfb31b3afb0690a 100644 (file)
  */
 use Friendica\Core\PConfig;
 
-require_once 'boot.php';
-
 function get_scheme_info($scheme)
 {
-       $theme = get_app()->getCurrentTheme();
+       $theme = \get_app()->getCurrentTheme();
        $themepath = 'view/theme/' . $theme . '/';
        $scheme = PConfig::get(local_user(), 'frio', 'scheme', PConfig::get(local_user(), 'frio', 'scheme'));
 
@@ -46,7 +44,11 @@ function get_scheme_info($scheme)
                foreach ($ll as $l) {
                        $l = trim($l, "\t\n\r */");
                        if ($l != '') {
-                               list($k, $v) = array_map('trim', explode(':', $l, 2));
+                               $values = array_map('trim', explode(':', $l, 2));
+                               if (count($values) < 2) {
+                                       continue;
+                               }
+                               list($k, $v) = $values;
                                $k = strtolower($k);
                                if ($k == 'author') {
                                        $r = preg_match('|([^<]+)<([^>]+)>|', $v, $m);