mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 12:20:22 +00:00
I18N: Merge similar strings in _deprecated_argument() calls.
Add translator comments. Props ramiy, SergeyBiryukov. Fixes #39020. git-svn-id: https://develop.svn.wordpress.org/trunk@40028 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1913,12 +1913,22 @@ function register_setting( $option_group, $option_name, $args = array() ) {
|
||||
}
|
||||
|
||||
if ( 'misc' == $option_group ) {
|
||||
_deprecated_argument( __FUNCTION__, '3.0.0', sprintf( __( 'The "%s" options group has been removed. Use another settings group.' ), 'misc' ) );
|
||||
_deprecated_argument( __FUNCTION__, '3.0.0',
|
||||
/* translators: %s: misc */
|
||||
sprintf( __( 'The "%s" options group has been removed. Use another settings group.' ),
|
||||
'misc'
|
||||
)
|
||||
);
|
||||
$option_group = 'general';
|
||||
}
|
||||
|
||||
if ( 'privacy' == $option_group ) {
|
||||
_deprecated_argument( __FUNCTION__, '3.5.0', sprintf( __( 'The "%s" options group has been removed. Use another settings group.' ), 'privacy' ) );
|
||||
_deprecated_argument( __FUNCTION__, '3.5.0',
|
||||
/* translators: %s: privacy */
|
||||
sprintf( __( 'The "%s" options group has been removed. Use another settings group.' ),
|
||||
'privacy'
|
||||
)
|
||||
);
|
||||
$option_group = 'reading';
|
||||
}
|
||||
|
||||
@@ -1949,12 +1959,22 @@ function unregister_setting( $option_group, $option_name, $deprecated = '' ) {
|
||||
global $new_whitelist_options, $wp_registered_settings;
|
||||
|
||||
if ( 'misc' == $option_group ) {
|
||||
_deprecated_argument( __FUNCTION__, '3.0.0', sprintf( __( 'The "%s" options group has been removed. Use another settings group.' ), 'misc' ) );
|
||||
_deprecated_argument( __FUNCTION__, '3.0.0',
|
||||
/* translators: %s: misc */
|
||||
sprintf( __( 'The "%s" options group has been removed. Use another settings group.' ),
|
||||
'misc'
|
||||
)
|
||||
);
|
||||
$option_group = 'general';
|
||||
}
|
||||
|
||||
if ( 'privacy' == $option_group ) {
|
||||
_deprecated_argument( __FUNCTION__, '3.5.0', sprintf( __( 'The "%s" options group has been removed. Use another settings group.' ), 'privacy' ) );
|
||||
_deprecated_argument( __FUNCTION__, '3.5.0',
|
||||
/* translators: %s: privacy */
|
||||
sprintf( __( 'The "%s" options group has been removed. Use another settings group.' ),
|
||||
'privacy'
|
||||
)
|
||||
);
|
||||
$option_group = 'reading';
|
||||
}
|
||||
|
||||
@@ -1963,7 +1983,13 @@ function unregister_setting( $option_group, $option_name, $deprecated = '' ) {
|
||||
unset( $new_whitelist_options[ $option_group ][ $pos ] );
|
||||
}
|
||||
if ( '' !== $deprecated ) {
|
||||
_deprecated_argument( __FUNCTION__, '4.7.0', __( '$sanitize_callback is deprecated. The callback from register_setting() is used instead.' ) );
|
||||
_deprecated_argument( __FUNCTION__, '4.7.0',
|
||||
/* translators: 1: $sanitize_callback, 2: register_setting() */
|
||||
sprintf( __( '%1$s is deprecated. The callback from %2$s is used instead.' ),
|
||||
'<code>$sanitize_callback</code>',
|
||||
'<code>register_setting()</code>'
|
||||
)
|
||||
);
|
||||
remove_filter( "sanitize_option_{$option_name}", $deprecated );
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user