X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FModule%2FThemeDetails.php;h=48c417412849b4817cfa2f2d506484cfcb0e8672;hb=f70650f8248b80915c051ffeefb723a23e0d4da7;hp=7b53d1cfde928f89cbf9fa92b536af59d455db7b;hpb=bd604d1cfb07fe43016f07a6d1f82877dd910b4c;p=friendica.git diff --git a/src/Module/ThemeDetails.php b/src/Module/ThemeDetails.php index 7b53d1cfde..48c4174128 100644 --- a/src/Module/ThemeDetails.php +++ b/src/Module/ThemeDetails.php @@ -1,4 +1,23 @@ . + * + */ namespace Friendica\Module; @@ -10,16 +29,16 @@ use Friendica\Core\Theme; */ class ThemeDetails extends BaseModule { - public static function rawContent() + public static function rawContent(array $parameters = []) { if (!empty($_REQUEST['theme'])) { $theme = $_REQUEST['theme']; $info = Theme::getInfo($theme); // Unfortunately there will be no translation for this string - $description = defaults($info, 'description', ''); - $version = defaults($info, 'version' , ''); - $credits = defaults($info, 'credits' , ''); + $description = $info['description'] ?? ''; + $version = $info['version'] ?? ''; + $credits = $info['credits'] ?? ''; echo json_encode([ 'img' => Theme::getScreenshot($theme),