Check $url variable for value before using it in Module\Photo::getPhotoById

- Address https://github.com/friendica/friendica/issues/12488#issuecomment-1407342540
This commit is contained in:
Hypolite Petovan 2023-01-29 00:12:59 -05:00
parent 9a270de9c2
commit 48a7958ef9

View File

@ -351,7 +351,7 @@ class Photo extends BaseModule
}
// If it is a local link, we save resources by just redirecting to it.
if (Network::isLocalLink($url)) {
if (!empty($url) && Network::isLocalLink($url)) {
System::externalRedirect($url);
}