From: fabrixxm Date: Sat, 17 Nov 2018 15:12:45 +0000 (+0100) Subject: Use appropriate redirect in dfrn_poll X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=1e9e06a325160a7b8707f2a8b828886fd1543afb;p=friendica.git Use appropriate redirect in dfrn_poll Got an error while remote auth to a local user, where $destination_url is relative. --- diff --git a/mod/dfrn_poll.php b/mod/dfrn_poll.php index 9cd110917f..ecca0adf7c 100644 --- a/mod/dfrn_poll.php +++ b/mod/dfrn_poll.php @@ -562,7 +562,11 @@ function dfrn_poll_content(App $a) break; default: $appendix = (strstr($destination_url, '?') ? '&f=&redir=1' : '?f=&redir=1'); - System::externalRedirect($destination_url . $appendix); + if (filter_var($url, FILTER_VALIDATE_URL)) { + System::externalRedirect($destination_url . $appendix); + } else { + $a->internalRedirect($destination_url . $appendix); + } break; } // NOTREACHED