Themes: Support second argument in theme support for custom logo.

See #33755.

Built from https://develop.svn.wordpress.org/trunk@36909


git-svn-id: http://core.svn.wordpress.org/trunk@36877 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Konstantin Obenland 2016-03-09 21:51:27 +00:00
parent 7441acafaf
commit dabfefcee2
2 changed files with 6 additions and 6 deletions

View File

@ -1751,6 +1751,7 @@ function get_theme_support( $feature ) {
$args = array_slice( func_get_args(), 1 );
switch ( $feature ) {
case 'custom-logo' :
case 'custom-header' :
case 'custom-background' :
if ( isset( $_wp_theme_features[ $feature ][0][ $args[0] ] ) )
@ -1877,12 +1878,11 @@ function current_theme_supports( $feature ) {
$type = $args[0];
return in_array( $type, $_wp_theme_features[$feature][0] );
case 'custom-logo':
case 'custom-header':
case 'custom-background' :
// specific custom header and background capabilities can be registered by passing
// an array to add_theme_support()
$header_support = $args[0];
return ( isset( $_wp_theme_features[$feature][0][$header_support] ) && $_wp_theme_features[$feature][0][$header_support] );
case 'custom-background':
// Specific capabilities can be registered by passing an array to add_theme_support().
return ( isset( $_wp_theme_features[ $feature ][0][ $args[0] ] ) && $_wp_theme_features[ $feature ][0][ $args[0] ] );
}
/**

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.5-beta2-36908';
$wp_version = '4.5-beta2-36909';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.