]> git.mxchange.org Git - friendica.git/blobdiff - mod/fbrowser.php
Merge pull request #12001 from tobiasd/20221016-docsmysql
[friendica.git] / mod / fbrowser.php
index 4e887c7eb0456a99a31452345ff79775d3d01c63..2f1181a8564b4a250700f28079e94a582d7e4110 100644 (file)
@@ -39,17 +39,15 @@ use Friendica\Util\Strings;
 function fbrowser_content(App $a)
 {
        if (!local_user()) {
-               DI::page()->logRuntime();
-               exit();
+               System::exit();
        }
 
        if (DI::args()->getArgc() == 1) {
-               DI::page()->logRuntime();
-               exit();
+               System::exit();
        }
 
        // Needed to match the correct template in a module that uses a different theme than the user/site/default
-       $theme = Strings::sanitizeFilePathItem($_GET['theme'] ?? null);
+       $theme = Strings::sanitizeFilePathItem($_GET['theme'] ?? '');
        if ($theme && is_file("view/theme/$theme/config.php")) {
                $a->setCurrentTheme($theme);
        }
@@ -105,7 +103,8 @@ function fbrowser_content(App $a)
                                return [
                                        DI::baseUrl() . '/photos/' . $a->getLoggedInUserNickname() . '/image/' . $rr['resource-id'],
                                        $filename_e,
-                                       DI::baseUrl() . '/photo/' . $rr['resource-id'] . '-' . $scale . '.'. $ext
+                                       DI::baseUrl() . '/photo/' . $rr['resource-id'] . '-' . $scale . '.'. $ext,
+                                       $rr['desc']
                                ];
                        }
                        $files = array_map("_map_files1", $r);