Remove temporary magic call method in favor of theme(), settings(), controls(), and sections() methods for WP_Customize_Manager. fixes #20736.

git-svn-id: https://develop.svn.wordpress.org/trunk@20860 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2012-05-23 21:21:29 +00:00
parent 50517b8e53
commit 11594ad693
1 changed files with 36 additions and 4 deletions

View File

@ -144,15 +144,47 @@ final class WP_Customize_Manager {
}
/**
* Generic getter.
* Get the theme being customized.
*
* @since 3.4.0
*
* @return WP_Theme
*/
public function __call( $callee, $args ) {
if ( in_array( $callee, array( 'theme', 'settings', 'controls', 'sections' ) ) )
return $this->$callee;
public function theme() {
return $this->theme;
}
/**
* Get the registered settings.
*
* @since 3.4.0
*
* @return array
*/
public function settings() {
return $this->settings;
}
/**
* Get the registered controls.
*
* @since 3.4.0
*
* @return array
*/
public function controls() {
return $this->controls;
}
/**
* Get the registered sections.
*
* @since 3.4.0
*
* @return array
*/
public function sections() {
return $this->sections;
}
/**