diff --git src/wp-includes/class-wp-theme.php src/wp-includes/class-wp-theme.php
index 523c733..3b80657 100644
|
|
final class WP_Theme implements ArrayAccess { |
1104 | 1104 | /** |
1105 | 1105 | * Filter the array of themes allowed on the site or network. |
1106 | 1106 | * |
1107 | | * @since MU |
| 1107 | * @since 4.2 |
1108 | 1108 | * |
1109 | 1109 | * @param array $allowed_themes An array of theme stylesheet names. |
1110 | 1110 | */ |
1111 | | $network = (array) apply_filters( 'allowed_themes', self::get_allowed_on_network() ); |
| 1111 | $network = (array) apply_filters( 'allowed_themes_combined', self::get_allowed_on_network(), $blog_id ); |
1112 | 1112 | return $network + self::get_allowed_on_site( $blog_id ); |
1113 | 1113 | } |
1114 | 1114 | |
… |
… |
final class WP_Theme implements ArrayAccess { |
1122 | 1122 | */ |
1123 | 1123 | public static function get_allowed_on_network() { |
1124 | 1124 | static $allowed_themes; |
1125 | | if ( ! isset( $allowed_themes ) ) |
1126 | | $allowed_themes = (array) get_site_option( 'allowedthemes' ); |
| 1125 | if ( ! isset( $allowed_themes ) ) { |
| 1126 | /** |
| 1127 | * Filter the array of themes allowed on the network. |
| 1128 | * |
| 1129 | * @since 4.2 |
| 1130 | * |
| 1131 | * @param array $allowed_themes An array of theme stylesheet names. |
| 1132 | */ |
| 1133 | $allowed_themes = (array) apply_filters( 'allowed_themes', get_site_option( 'allowedthemes' ) ); |
| 1134 | } |
1127 | 1135 | return $allowed_themes; |
1128 | 1136 | } |
1129 | 1137 | |
… |
… |
final class WP_Theme implements ArrayAccess { |
1191 | 1199 | } |
1192 | 1200 | } |
1193 | 1201 | |
1194 | | return (array) $allowed_themes[ $blog_id ]; |
| 1202 | /** |
| 1203 | * Filter the array of themes allowed on the site. |
| 1204 | * |
| 1205 | * @since 4.2 |
| 1206 | * |
| 1207 | * @param array $allowed_themes An array of theme stylesheet names. |
| 1208 | */ |
| 1209 | $allowed_themes = (array) apply_filters( 'allowed_themes_site', $allowed_themes[ $blog_id ], $blog_id ); |
| 1210 | return $allowed_themes; |
1195 | 1211 | } |
1196 | 1212 | |
1197 | 1213 | /** |