summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-08-07 09:39:00 +0000
committerdonncha <donncha@7be80a69-a1ef-0310-a953-fb0f7c49ff36>2007-08-07 09:39:00 +0000
commitfc4f046efa8143ebc84c4ed5c44239fa0ea6f362 (patch)
treec8cfbdabb32e8887fdcc388fefc4d63be40c3564
parent264bfb064348e9263067317e99c18f40efcfe295 (diff)
downloadwordpress-mu-fc4f046efa8143ebc84c4ed5c44239fa0ea6f362.tar.gz
wordpress-mu-fc4f046efa8143ebc84c4ed5c44239fa0ea6f362.tar.xz
wordpress-mu-fc4f046efa8143ebc84c4ed5c44239fa0ea6f362.zip
Fix the allowed_themes loop (fixes #369, props aydos)
git-svn-id: http://svn.automattic.com/wordpress-mu/trunk@1019 7be80a69-a1ef-0310-a953-fb0f7c49ff36
-rw-r--r--wp-admin/admin-db.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/wp-admin/admin-db.php b/wp-admin/admin-db.php
index d296e74..662d56f 100644
--- a/wp-admin/admin-db.php
+++ b/wp-admin/admin-db.php
@@ -676,15 +676,15 @@ function get_site_allowed_themes() {
$allowed_themes = get_site_option( "allowed_themes" ); // convert old allowed_themes format
if( !is_array( $allowed_themes ) ) {
$allowed_themes = array();
- continue;
- }
- foreach( $themes as $key => $theme ) {
- $theme_key = wp_specialchars( $theme[ 'Stylesheet' ] );
- if( isset( $allowed_themes[ $key ] ) == true ) {
- $allowedthemes[ $theme_key ] = 1;
+ } else {
+ foreach( $themes as $key => $theme ) {
+ $theme_key = wp_specialchars( $theme[ 'Stylesheet' ] );
+ if( isset( $allowed_themes[ $key ] ) == true ) {
+ $allowedthemes[ $theme_key ] = 1;
+ }
}
+ $allowed_themes = $allowedthemes;
}
- $allowed_themes = $allowedthemes;
}
return $allowed_themes;