Remove PHP4 constructors. Props hakre. see #16768

git-svn-id: https://develop.svn.wordpress.org/trunk@17604 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2011-04-05 17:25:08 +00:00
parent 9691cb5eb2
commit d470b22d59
4 changed files with 4 additions and 43 deletions

View File

@ -456,17 +456,6 @@ class WP_Object_Cache {
echo '</ul>';
}
/**
* PHP4 constructor; Calls PHP 5 style constructor
*
* @since 2.0.0
*
* @return WP_Object_Cache
*/
function WP_Object_Cache() {
return $this->__construct();
}
/**
* Sets up object properties; PHP 5 style constructor
*

View File

@ -73,14 +73,11 @@ class WP_Roles {
var $use_db = true;
/**
* PHP4 Constructor - Call {@link WP_Roles::_init()} method.
* Constructor
*
* @since 2.0.0
* @access public
*
* @return WP_Roles
*/
function WP_Roles() {
function __construct() {
$this->_init();
}
@ -269,7 +266,7 @@ class WP_Role {
var $capabilities;
/**
* PHP4 Constructor - Set up object properties.
* Constructor - Set up object properties.
*
* The list of capabilities, must have the key as the name of the capability
* and the value a boolean of whether it is granted to the role.
@ -279,9 +276,8 @@ class WP_Role {
*
* @param string $role Role name.
* @param array $capabilities List of capabilities.
* @return WP_Role
*/
function WP_Role( $role, $capabilities ) {
function __construct( $role, $capabilities ) {
$this->name = $role;
$this->capabilities = $capabilities;
}

View File

@ -25,13 +25,6 @@ class WP_Dependencies {
var $groups = array();
var $group = 0;
function WP_Dependencies() {
$args = func_get_args();
call_user_func_array( array(&$this, '__construct'), $args );
}
function __construct() {}
/**
* Do the dependencies
*

View File

@ -461,23 +461,6 @@ class wpdb {
*/
var $func_call;
/**
* Connects to the database server and selects a database
*
* PHP4 compatibility layer for calling the PHP5 constructor.
*
* @uses wpdb::__construct() Passes parameters and returns result
* @since 0.71
*
* @param string $dbuser MySQL database user
* @param string $dbpassword MySQL database password
* @param string $dbname MySQL database name
* @param string $dbhost MySQL database host
*/
function wpdb( $dbuser, $dbpassword, $dbname, $dbhost ) {
return $this->__construct( $dbuser, $dbpassword, $dbname, $dbhost );
}
/**
* Connects to the database server and selects a database
*