]> git.mxchange.org Git - friendica.git/commitdiff
Improvement for PR 3705: The detection has to be changed here as well
authorMichael <heluecht@pirati.ca>
Sat, 16 Sep 2017 17:22:22 +0000 (17:22 +0000)
committerMichael <heluecht@pirati.ca>
Sat, 16 Sep 2017 17:22:22 +0000 (17:22 +0000)
include/diaspora.php

index 8bfba6eff41d68c96cc0afccd3abc63b0a76172e..af934cc937de1349865cce5794de3e5c0f4a2f23 100644 (file)
@@ -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"]);