prepare for general docs prepended by ": "
authorMichael Wallner <mike@php.net>
Wed, 20 Aug 2014 13:45:11 +0000 (15:45 +0200)
committerMichael Wallner <mike@php.net>
Wed, 20 Aug 2014 13:45:11 +0000 (15:45 +0200)
mdref/RefEntry.php

index 9db99f7aa529a16a98e9574b9e8883087bacb743..2ad3d278b617308af441f95069477df2337d7363 100644 (file)
@@ -56,13 +56,15 @@ class RefEntry
                                continue;
                        }
                        if (strlen($link)) {
-                               if ($upper && !ctype_upper($parts[$i][0])) {
+                               if ($parts[$i][0] === ":") {
+                                       $link = "";
+                               } elseif ($upper && !ctype_upper($parts[$i][0])) {
                                        $link .= "::";
                                } else {
                                        $link .= "\\";
                                }
                        }
-                       $link .= $parts[$i];
+                       $link .= trim($parts[$i], ": ");
                        $upper = ctype_upper($parts[$i][0]);
                }
                return $link;