mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 09:37:42 +01:00
Check if $uris is an array.
git-svn-id: http://svn.automattic.com/wordpress/trunk@1757 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
4f0449f79b
commit
d1d02a30bb
@ -1250,9 +1250,12 @@ function page_rewrite_rules() {
|
||||
$uris = get_settings('page_uris');
|
||||
|
||||
$rewrite_rules = array();
|
||||
foreach ($uris as $uri => $pagename) {
|
||||
$rewrite_rules += array($uri . '/?$' => "index.php?pagename=$pagename");
|
||||
}
|
||||
if( is_array( $uris ) )
|
||||
{
|
||||
foreach ($uris as $uri => $pagename) {
|
||||
$rewrite_rules += array($uri . '/?$' => "index.php?pagename=$pagename");
|
||||
}
|
||||
}
|
||||
|
||||
return $rewrite_rules;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user