Don't double requested url in url_to_postid(). Props filosofo. fixes #5661

git-svn-id: http://svn.automattic.com/wordpress/trunk@6614 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2008-01-14 21:44:08 +00:00
parent 61881b5111
commit 0866e1e584
1 changed files with 1 additions and 1 deletions

View File

@ -127,7 +127,7 @@ function url_to_postid($url) {
foreach ($rewrite as $match => $query) {
// If the requesting file is the anchor of the match, prepend it
// to the path info.
if ( (! empty($url)) && (strpos($match, $url) === 0) ) {
if ( (! empty($url)) && (strpos($match, $url) === 0) && ($url != $request)) {
$request_match = $url . '/' . $request;
}