]> git.mxchange.org Git - friendica.git/blobdiff - mod/dfrn_poll.php
Fix introductions notifications links
[friendica.git] / mod / dfrn_poll.php
index 5e5540be140a65db3a28e51e25362347f9563370..54539ee03d7bd4cc580bb7845b9fa34b59734488 100644 (file)
@@ -480,6 +480,12 @@ function dfrn_poll_content(App $a)
                }
 
                if (($type === 'profile') && (strlen($sec))) {
+                       // heluecht: I don't know why we don't fail immediately when the user or contact hadn't been found.
+                       // Since it doesn't make sense to continue from this point on, we now fail here. This should be safe.
+                       if (!DBA::isResult($r)) {
+                               System::httpExit(404, ["title" => L10n::t('Page not found.')]);
+                       }
+
                        // URL reply
                        if ($dfrn_version < 2.2) {
                                $s = Network::fetchUrl($r[0]['poll']