Some classes with __get() method also need __set().

See #27881, #22234.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28347 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Scott Taylor
2014-05-19 06:31:15 +00:00
parent 2e9ce6fc87
commit 821246b4ae
9 changed files with 110 additions and 1 deletions

View File

@@ -69,6 +69,19 @@ class Custom_Background {
return $this->$name;
}
/**
* Make private properties setable for backwards compatibility
*
* @since 4.0.0
* @param string $name
* @param string $value
* @return mixed
*/
public function __set( $name, $value ) {
return $this->$name = $value;
}
/**
* Set up the hooks for the Custom Background admin page.
*