Don't try to do permalinks for admin pages.

git-svn-id: http://svn.automattic.com/wordpress/trunk@3226 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2005-11-28 23:30:42 +00:00
parent ef2c2c4cb9
commit cba87fb462
1 changed files with 10 additions and 9 deletions

View File

@ -1482,27 +1482,28 @@ class WP {
// If we're processing a 404 request, clear the error var // If we're processing a 404 request, clear the error var
// since we found something. // since we found something.
if (isset($_GET['error'])) { if (isset($_GET['error']))
unset($_GET['error']); unset($_GET['error']);
}
if (isset($error)) { if (isset($error))
unset($error); unset($error);
}
break; break;
} }
} }
// If req_uri is empty or if it is a request for ourself, unset error. // If req_uri is empty or if it is a request for ourself, unset error.
if ( empty($request) || $req_uri == $self ) { if ( empty($request) || $req_uri == $self || strstr($_SERVER['PHP_SELF'], 'wp-admin/') ) {
if (isset($_GET['error'])) { if (isset($_GET['error']))
unset($_GET['error']); unset($_GET['error']);
}
if (isset($error)) { if (isset($error))
unset($error); unset($error);
}
if ( isset($query_vars) )
unset($query_vars);
$this->did_permalink = false;
} }
} }