From: Michael Vogel Date: Sun, 8 Feb 2015 09:48:04 +0000 (+0100) Subject: GNU Social, Pump.io, Twitter: Improved check for posts that originally come from... X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=4769c81e26b130fa1e2d9243ccbd090c1975300c;p=friendica-addons.git GNU Social, Pump.io, Twitter: Improved check for posts that originally come from friendica to prevent mirroring them. --- diff --git a/convpath/convpath.php b/convpath/convpath.php index 8deb46cf..0aaeb5f9 100644 --- a/convpath/convpath.php +++ b/convpath/convpath.php @@ -4,7 +4,7 @@ * Description: Converts all internal paths according to the current scheme (http or https) * Version: 1.0 * Author: Michael Vogel - * + * Status: Unsupported */ function convpath_install() { diff --git a/pumpio/pumpio.php b/pumpio/pumpio.php index cb2ee000..51e34e60 100644 --- a/pumpio/pumpio.php +++ b/pumpio/pumpio.php @@ -731,7 +731,7 @@ function pumpio_fetchtimeline(&$a, $uid) { if ($receiver->id == "http://activityschema.org/collection/public") $public = true; - if ($public AND !strstr($post->generator->displayName, $application_name)) { + if ($public AND !stristr($post->generator->displayName, $application_name)) { require_once('include/html2bbcode.php'); $_SESSION["authenticated"] = true; diff --git a/statusnet/statusnet.php b/statusnet/statusnet.php index f4dc7553..6713842e 100644 --- a/statusnet/statusnet.php +++ b/statusnet/statusnet.php @@ -838,7 +838,7 @@ function statusnet_fetchtimeline($a, $uid) { if ($post->in_reply_to_status_id != "") continue; - if (!strpos($post->source, $application_name)) { + if (!stristr($post->source, $application_name)) { $_SESSION["authenticated"] = true; $_SESSION["uid"] = $uid; diff --git a/twitter/twitter.php b/twitter/twitter.php index 3919bf8b..f0076703 100644 --- a/twitter/twitter.php +++ b/twitter/twitter.php @@ -751,7 +751,7 @@ function twitter_fetchtimeline($a, $uid) { if ($first_time) continue; - if (!strpos($post->source, $application_name)) { + if (!stristr($post->source, $application_name)) { $_SESSION["authenticated"] = true; $_SESSION["uid"] = $uid;