From: Michael Date: Sat, 16 Sep 2017 17:22:22 +0000 (+0000) Subject: Improvement for PR 3705: The detection has to be changed here as well X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=0982a30c89eb143ad62d46e8c6389da9480da4cf;p=friendica.git Improvement for PR 3705: The detection has to be changed here as well --- diff --git a/include/diaspora.php b/include/diaspora.php index 8bfba6eff4..af934cc937 100644 --- a/include/diaspora.php +++ b/include/diaspora.php @@ -1013,7 +1013,8 @@ class Diaspora { * @param array $item The item array */ private static function fetch_guid($item) { - preg_replace_callback("=diaspora://.*?/([^\s\]]*)=ism", + $expression = "=diaspora://.*?/post/([0-9A-Za-z\-_@.:]{15,254}[0-9A-Za-z])=ism"; + preg_replace_callback($expression, function ($match) use ($item) { return self::fetch_guid_sub($match, $item); }, $item["body"]);