mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-12 21:00:21 +00:00
Docs: Use 3-digit, x.x.x-style semantic versioning for _doing_it_wrong(), _deprecated_function(), _deprecated_argument(), and _deprecated_file() throughout core.
Props metodiew. Fixes #36495. git-svn-id: https://develop.svn.wordpress.org/trunk@37985 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1135,7 +1135,7 @@ class wpdb {
|
||||
*/
|
||||
function _weak_escape( $string ) {
|
||||
if ( func_num_args() === 1 && function_exists( '_deprecated_function' ) )
|
||||
_deprecated_function( __METHOD__, '3.6', 'wpdb::prepare() or esc_sql()' );
|
||||
_deprecated_function( __METHOD__, '3.6.0', 'wpdb::prepare() or esc_sql()' );
|
||||
return addslashes( $string );
|
||||
}
|
||||
|
||||
@@ -1209,7 +1209,7 @@ class wpdb {
|
||||
*/
|
||||
public function escape( $data ) {
|
||||
if ( func_num_args() === 1 && function_exists( '_deprecated_function' ) )
|
||||
_deprecated_function( __METHOD__, '3.6', 'wpdb::prepare() or esc_sql()' );
|
||||
_deprecated_function( __METHOD__, '3.6.0', 'wpdb::prepare() or esc_sql()' );
|
||||
if ( is_array( $data ) ) {
|
||||
foreach ( $data as $k => $v ) {
|
||||
if ( is_array( $v ) )
|
||||
@@ -1278,7 +1278,7 @@ class wpdb {
|
||||
|
||||
// This is not meant to be foolproof -- but it will catch obviously incorrect usage.
|
||||
if ( strpos( $query, '%' ) === false ) {
|
||||
_doing_it_wrong( 'wpdb::prepare', sprintf( __( 'The query argument of %s must have a placeholder.' ), 'wpdb::prepare()' ), '3.9' );
|
||||
_doing_it_wrong( 'wpdb::prepare', sprintf( __( 'The query argument of %s must have a placeholder.' ), 'wpdb::prepare()' ), '3.9.0' );
|
||||
}
|
||||
|
||||
$args = func_get_args();
|
||||
@@ -3210,7 +3210,7 @@ class wpdb {
|
||||
* @return bool True if collation is supported, false if version does not
|
||||
*/
|
||||
public function supports_collation() {
|
||||
_deprecated_function( __FUNCTION__, '3.5', 'wpdb::has_cap( \'collation\' )' );
|
||||
_deprecated_function( __FUNCTION__, '3.5.0', 'wpdb::has_cap( \'collation\' )' );
|
||||
return $this->has_cap( 'collation' );
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user